PHPackages                             jotweh/codeception-monolog - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Logging &amp; Monitoring](/categories/logging)
4. /
5. jotweh/codeception-monolog

ActiveLibrary[Logging &amp; Monitoring](/categories/logging)

jotweh/codeception-monolog
==========================

Monolog Extension for Codeception

1.1.0(11y ago)07041MITPHP

Since Feb 11Pushed 11y ago1 watchersCompare

[ Source](https://github.com/jotweh/codeception-monolog)[ Packagist](https://packagist.org/packages/jotweh/codeception-monolog)[ Docs](https://github.com/jotweh/codeception-monolog)[ RSS](/packages/jotweh-codeception-monolog/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (4)Versions (3)Used By (0)

codeception-monolog
===================

[](#codeception-monolog)

What is it?
-----------

[](#what-is-it)

The default Codeception Logger extension (see ) always uses a `RotatingFileHandler` for Logging, which writes to a `codeception-.log` file. This was not sufficient for me so I created this configurable Monolog logging extension. It allows usage of multiple log handlers with custom configuration (see below for an example). Currently only log handlers are supported, that do *not* require objects in their constructor parameters, such as:

- NativeMailHandler
- FirePHPHandler
- RotatingFileHandler
- HipChatHandler
- ErrorLogHandler
- ...

The log handlers will currently only be triggered in case of a failed test.

Installation
------------

[](#installation)

Currently not available via packagist, so you'll have to add this to your `composer.json`:

```
  ...
  "repositories": [
    {
      "type": "vcs",
      "url": "git@github.com:jotweh/codeception-monolog.git"
    }
  ],
  "require": {
    "jotweh/codeception-monolog": "dev-master",
    ...
  }
  ...

```

Configuration
-------------

[](#configuration)

Enable the Extension in your `codeception.yaml` like this:

```
extensions:
    enabled:
        - Codeception\Extension\CodeceptionMonolog

```

You can configure multiple log handlers in your `codeception.yaml`:

```
extensions:
    enabled:
        - Codeception\Extension\CodeceptionMonolog
    config:
            Codeception\Extension\CodeceptionMonolog:
                message: "Test %s failed. Please check. Error Message: %s."
                handlers:
                    NativeMailerHandler:
                          to: 'test@example.com,othertest@example.com'
                          subject: 'Email Subject'
                          from: 'Monitoring'
                          level: 400 #error log level
                    HipChatHandler:
                          token: 'somecryptichipchattoken'
                          room: 'HipChatRoomName'
                          name: 'Notifier'
                          notify: true
                          level: 400 #error log level

```

In the `handlers` section, each key is a Monolog handler class name. The values are the constructor parameters for the handler. In the example above, the HipChatHandler and the NativeMailerHandler are used. So when a test fails, an email and a hipchat notification will be sent.

###  Health Score

30

—

LowBetter than 64% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity64

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~2 days

Total

2

Last Release

4112d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/9f4f9173100adcc63dd605b7eb8789701b84679e7517c24d85047d93c5e29443?d=identicon)[jotweh](/maintainers/jotweh)

---

Top Contributors

[![jotweh](https://avatars.githubusercontent.com/u/4070475?v=4)](https://github.com/jotweh "jotweh (2 commits)")

---

Tags

loggingmonitoringcodeceptionmonolog

### Embed Badge

![Health badge](/badges/jotweh-codeception-monolog/health.svg)

```
[![Health](https://phpackages.com/badges/jotweh-codeception-monolog/health.svg)](https://phpackages.com/packages/jotweh-codeception-monolog)
```

###  Alternatives

[rollbar/rollbar

Monitors errors and exceptions and reports them to Rollbar

33723.7M82](/packages/rollbar-rollbar)[inpsyde/wonolog

Monolog-based logging package for WordPress.

183617.9k7](/packages/inpsyde-wonolog)[honeybadger-io/honeybadger-laravel

Honeybadger Laravel integration

431.2M](/packages/honeybadger-io-honeybadger-laravel)[honeybadger-io/honeybadger-php

Honeybadger PHP library

381.5M4](/packages/honeybadger-io-honeybadger-php)[logtail/monolog-logtail

Logtail handler for Monolog

233.2M3](/packages/logtail-monolog-logtail)[kdyby/monolog

Integration of Monolog into Nette Framework

33684.0k10](/packages/kdyby-monolog)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
