PHPackages                             ostark/craft-mute-deprecations - 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. ostark/craft-mute-deprecations

ActiveYii2-extension[Logging &amp; Monitoring](/categories/logging)

ostark/craft-mute-deprecations
==============================

Mutes deprecation logs in production

035PHP

Since Apr 5Pushed 8y ago1 watchersCompare

[ Source](https://github.com/ostark/craft-mute-deprecations)[ Packagist](https://packagist.org/packages/ostark/craft-mute-deprecations)[ RSS](/packages/ostark-craft-mute-deprecations/feed)WikiDiscussions master Synced 2w ago

READMEChangelogDependenciesVersions (1)Used By (0)

Mute Craft deprecations in production
=====================================

[](#mute-craft-deprecations-in-production)

When migrating a site from Craft 2 to Craft 3, you will notice things [changed in the templates](https://docs.craftcms.com/v3/changes-in-craft-3.html#template-functions). Twig tags got renamed and variable access is slightly different - they old way is usually still supported, but is marked as "deprecated".

This extension prevents Craft from logging deprecation errors if `'devMode' => false` in `config/general.php`. It speeds up your site by reducing overhead of tracing the code and logging to the database.

**Notice: Do not simply mute deprecation errors, remove them as soon as possible.**

Why?
----

[](#why)

The benefits of this package are very limited. It is rather an example of how to use a Yii extension with Craft instead of a Plugin.

With this `extra` option in the `composer.json` you hook into Yii's bootstrapping process:

```
"extra": {
    "bootstrap": "ostark\\MuteDeprecations\\Bootstrap"
}

```

In the [Bootstrap class](https://github.com/ostark/craft-mute-deprecations/blob/master/src/Bootstrap.php), you learn how to access the `Craft::$app` instance, to use services and to swap out a Craft core component from the container.

Links
-----

[](#links)

-
-

Install
-------

[](#install)

Require the package:

```
composer require ostark/craft-mute-deprecations

```

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity7

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

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.

### Community

Maintainers

![](https://www.gravatar.com/avatar/8f2939b15a562ee53b5284f58b704e53ae26b975c1154fa6afb2f8b8331fbd27?d=identicon)[ostark](/maintainers/ostark)

---

Tags

craftcmsexampleyii2yii2-extension

### Embed Badge

![Health badge](/badges/ostark-craft-mute-deprecations/health.svg)

```
[![Health](https://phpackages.com/badges/ostark-craft-mute-deprecations/health.svg)](https://phpackages.com/packages/ostark-craft-mute-deprecations)
```

###  Alternatives

[psr/log

Common interface for logging libraries

10.4k1.2B10.9k](/packages/psr-log)[open-telemetry/api

API for OpenTelemetry PHP.

1938.5M263](/packages/open-telemetry-api)[open-telemetry/sdk

SDK for OpenTelemetry PHP.

2326.5M317](/packages/open-telemetry-sdk)[illuminated/console-logger

Logging and Notifications for Laravel Console Commands.

8676.7k](/packages/illuminated-console-logger)

PHPackages © 2026

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