Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: undefined method bootstrap() #76

Open
1 task done
tserofcj opened this issue Feb 8, 2024 · 1 comment
Open
1 task done

[Bug]: undefined method bootstrap() #76

tserofcj opened this issue Feb 8, 2024 · 1 comment
Labels

Comments

@tserofcj
Copy link

tserofcj commented Feb 8, 2024

Description of the bug

hello,
i updated my composer dependencies to be able to use php 8.1. I went with monolog/monolog 2.* and inpsyde/wonolog 2.0.0-beta.2
But now in my mu-plugin the Inpsyde\Wonolog\bootstrap(); is undefined and i have a PHP error. If i remove the bootstrap() i have no error, but also no logs.
i tried to call the makeLogger() method but no success.
What should we do with this new version?
Thanks for your help

Reproduction instructions

update your composer.json with

"inpsyde/wonolog": "2.0.0-beta.2",
"monolog/monolog": "^2.9.2"

do a composer update
in a mu-plugin, instantiate wonolog and create a log :

Inpsyde\Wonolog\bootstrap();
do_action( 'wonolog.log', 'test');

Expected behavior

we should have a folder wonolog/2024/02/08.log with our log

Environment info

PHP 8.1
wonolog 2.0.0-beta.2
monolog 2.9.2

Relevant log output

No response

Additional context

No response

Code of Conduct

  • I agree to follow this project's Code of Conduct
@tserofcj tserofcj added the bug label Feb 8, 2024
@chesio
Copy link
Contributor

chesio commented Feb 12, 2024

Hello @tserofcj,

this is expected with version 2 as there is no bootstrap method any more. See the docs: https://github.com/inpsyde/Wonolog/blob/2.x/docs/02-bootstrap-and-configuration-gateway.md#the-setup-hook

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants