Skip to content

Conversation

@dependabot
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github May 27, 2022

Updates the requirements on monolog/monolog to permit the latest version.

Release notes

Sourced from monolog/monolog's releases.

3.0.0

This is mostly a cleanup release offering stronger type guarantees for integrators with the array->object/enum changes, but there is no big new feature for end users.

See UPGRADE notes for details on all breaking changes especially if you are extending/implementing Monolog classes/interfaces.

Noteworthy BC Breaks:

  • The minimum supported PHP version is now 8.1.0.
  • Log records have been converted from an array to a Monolog\LogRecord object with public (and mostly readonly) properties. e.g. instead of doing $record['context'] use $record->context. In formatters or handlers if you rather need an array to work with you can use $record->toArray() to get back a Monolog 1/2 style record array. This will contain the enum values instead of enum cases in the level and level_name keys to be more backwards compatible and use simpler data types.
  • FormatterInterface, HandlerInterface, ProcessorInterface, etc. changed to contain LogRecord $record instead of array $record parameter types. If you want to support multiple Monolog versions this should be possible by type-hinting nothing, or array|LogRecord if you support PHP 8.0+. You can then code against the $record using Monolog 2 style as LogRecord implements ArrayAccess for BC. The interfaces do not require a LogRecord return type even where it would be applicable, but if you only support Monolog 3 in integration code I would recommend you use LogRecord return types wherever fitting to ensure forward compatibility as it may be added in Monolog 4.
  • Log levels are now stored as an enum Monolog\Level
  • Removed deprecated SwiftMailerHandler, migrate to SymfonyMailerHandler instead.
  • ResettableInterface::reset() now requires a void return type.
  • All properties have had types added, which may require you to do so as well if you extended a Monolog class and declared the same property.

New deprecations:

  • Logger::DEBUG, Logger::ERROR, etc. are now deprecated in favor of the Monolog\Level enum. e.g. instead of Logger::WARNING use Level::Warning if you need to pass the enum case to Monolog or one of its handlers, or Level::Warning->value if you need the integer value equal to what Logger::WARNING was giving you.
  • Logger::getLevelName() is now deprecated.
Changelog

Sourced from monolog/monolog's changelog.

3.0.0 (2022-05-10)

Changes from RC1

  • The Monolog\LevelName enum does not exist anymore, use Monolog\Level->getName() instead.

3.0.0-RC1 (2022-05-08)

This is mostly a cleanup release offering stronger type guarantees for integrators with the array->object/enum changes, but there is no big new feature for end users.

See UPGRADE notes for details on all breaking changes especially if you are extending/implementing Monolog classes/interfaces.

Noteworthy BC Breaks:

  • The minimum supported PHP version is now 8.1.0.
  • Log records have been converted from an array to a Monolog\LogRecord object with public (and mostly readonly) properties. e.g. instead of doing $record['context'] use $record->context. In formatters or handlers if you rather need an array to work with you can use $record->toArray() to get back a Monolog 1/2 style record array. This will contain the enum values instead of enum cases in the level and level_name keys to be more backwards compatible and use simpler data types.
  • FormatterInterface, HandlerInterface, ProcessorInterface, etc. changed to contain LogRecord $record instead of array $record parameter types. If you want to support multiple Monolog versions this should be possible by type-hinting nothing, or array|LogRecord if you support PHP 8.0+. You can then code against the $record using Monolog 2 style as LogRecord implements ArrayAccess for BC. The interfaces do not require a LogRecord return type even where it would be applicable, but if you only support Monolog 3 in integration code I would recommend you use LogRecord return types wherever fitting to ensure forward compatibility as it may be added in Monolog 4.
  • Log levels are now enums Monolog\Level and Monolog\LevelName
  • Removed deprecated SwiftMailerHandler, migrate to SymfonyMailerHandler instead.
  • ResettableInterface::reset() now requires a void return type.
  • All properties have had types added, which may require you to do so as well if you extended a Monolog class and declared the same property.

New deprecations:

  • Logger::DEBUG, Logger::ERROR, etc. are now deprecated in favor of the Monolog\Level enum. e.g. instead of Logger::WARNING use Level::Warning if you need to pass the enum case to Monolog or one of its handlers, or Level::Warning->value if you need the integer value equal to what Logger::WARNING was giving you.
  • Logger::getLevelName() is now deprecated.

2.6.0 (2022-05-10)

  • Deprecated SwiftMailerHandler, use SymfonyMailerHandler instead
  • Added SymfonyMailerHandler (#1663)
  • Added ElasticSearch 8.x support to the ElasticsearchHandler (#1662)
  • Added a way to filter/modify stack traces in LineFormatter (#1665)
  • Fixed UdpSocket not being able to reopen/reconnect after close()

... (truncated)

Commits
  • 60ad518 Update changelog
  • b3451b0 Merge branch '2.x' into main
  • 2479189 Update changelog
  • 1dacc79 Remove LevelName enum in favor of a Level::getName method, fixes #1667 (#1668)
  • a5d65f6 Fix infinite loops when a log handler triggers logging itself
  • 5d43fd5 Allow UdpSocket to reconnect after close()
  • c709906 [2.X] Allow stacktraces parser on LineFormatter (#1665)
  • 2a8c7df Also allow for slow ES8 start
  • d381140 Merge branch '2.x' into main
  • 2af3276 Update list of handlers
  • Additional commits viewable in compare view

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

@dependabot dependabot bot added dependencies Pull requests that update a dependency file RFR labels May 27, 2022
Copy link

@etsglobalbv-bot etsglobalbv-bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm approving this PR because it was created by Dependabot

@aallier aallier force-pushed the dependabot/composer/monolog/monolog-tw-2.0or-tw-3.0 branch from efa0dc5 to 0ce8d6d Compare July 29, 2022 16:00
@dependabot @github
Copy link
Contributor Author

dependabot bot commented on behalf of github Jul 29, 2022

A newer version of monolog/monolog exists, but since this PR has been edited by someone other than Dependabot I haven't updated it. You'll get a PR for the updated version as normal once this PR is merged.

@aallier aallier force-pushed the dependabot/composer/monolog/monolog-tw-2.0or-tw-3.0 branch from 0ce8d6d to c97b48b Compare August 2, 2022 07:19
Updates the requirements on [monolog/monolog](https://github.com/Seldaek/monolog) to permit the latest version.
- [Release notes](https://github.com/Seldaek/monolog/releases)
- [Changelog](https://github.com/Seldaek/monolog/blob/main/CHANGELOG.md)
- [Commits](Seldaek/monolog@2.0.0...3.0.0)

---
updated-dependencies:
- dependency-name: monolog/monolog
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
@aallier aallier force-pushed the dependabot/composer/monolog/monolog-tw-2.0or-tw-3.0 branch from c97b48b to b61a262 Compare August 3, 2022 13:48
@aallier aallier requested review from a team, ketlane and xunleii August 3, 2022 13:53
@aallier aallier merged commit d3a631e into master Aug 5, 2022
@aallier aallier deleted the dependabot/composer/monolog/monolog-tw-2.0or-tw-3.0 branch August 5, 2022 08:21
Copy link

@ch3ric ch3ric left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"php": "^8.1",
"ext-json": "*",
"monolog/monolog": "^2.0",
"monolog/monolog": "^2.0 || ^3.0",
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

because you've used LogRecord this version does not support monolog ^2.0 anymore

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

#26

@ch3ric
Copy link

ch3ric commented Aug 26, 2022

fixed in #26
✔️

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file RFR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants