-
Notifications
You must be signed in to change notification settings - Fork 32
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
PSR-4 autoloading doesn't work #19
Comments
Thank you for this detailed bug report @armin-crosslend! I appreciate the information, and will look at this in the coming days! |
As a temporary solution I added a fixed class map to composer:
And later in our
For Monolog v1 just change the folder to This makes composer with |
The This appears to be a deliberate choice based on the comment in the AbstractFormatter
|
Some updates about this issue, folks? |
The latest version of Composer v1 complains similarly: Deprecation Notice: Class NewRelic\Monolog\Enricher\AbstractHandler located in ./vendor/newrelic/monolog-enricher/src/Handler.php does not comply with psr-4 autoloading standard. It will not autoload anymore in Composer v2.0. in phar:///usr/local/bin/composer/src/Composer/Autoload/ClassMapGenerator.php:201
Deprecation Notice: Class NewRelic\Monolog\Enricher\AbstractFormatter located in ./vendor/newrelic/monolog-enricher/src/Formatter.php does not comply with psr-4 autoloading standard. It will not autoload anymore in Composer v2.0. in phar:///usr/local/bin/composer/src/Composer/Autoload/ClassMapGenerator.php:201 |
Having the same issue. The best solution would be to create two versions of the library, one which explicitly needs Monolog 1.* and another for 2.* |
Thanks for all your feedback on this. We will work on creating two versions of the library, one for Monolog 1, another for Monolog 2 versions. |
With the release of Composer 2 this is now again an issue. Do you have a guesstimate on the split library ETA? |
The idea is to maintain two release branches of this library, correct? |
Yes @cilefen, that's what we plan to do. |
@pyohannes please can you speak to your managers at NewRelic on getting this change prioritized? It is a massive blocker for me, and many other people. I have customers who are paying loads of money to NewRelic platform already, and we're relying on this library to use your platform for logging, instead of Google Cloud. Thanks. UPDATE: I see @pyohannes you're at Microsoft, not NewRelic. Who is the point of contact for this? |
This issue has been logged for almost a year now. Any chance we can get a proper fix for this? |
That's it for me, moving to Logflare. The NewRelic platform is an actual bottleneck instead of an Observability Platform, like they advertise. Any bug takes years to solve, interface is very slow. Not worth spending life time with it. |
Feeling like I should give DataDog a try. New Relic interface is alot more
clunky these days and way slower. Also this PSR4 issue is ridiculous.
…On Sat, Feb 20, 2021 at 6:59 AM Lucian Daniliuc ***@***.***> wrote:
That's it for me, moving to Logflare. The NewRelic platform is an actual
bottleneck instead of an Observability Platform, like they advertise. Any
bug takes years to solve, interface is *very* slow. Not worth spending
life time with it.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#19 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAGT6XS7PGZATISKKZIX6VTS7654LANCNFSM4LWSTIGA>
.
--
-------------------
Steve Barbera
whobutsb@gmail.com
|
We'd like to thank the community for your patience and engagement in this issue. We understand your frustrations with the delay and lack of transparency on the timeline for this for which we sincerely apologize. The fix is now in with release 2.0.0! :) We hope you'll give it a try. |
Description
I've tried using this package with our Symfony 5 installation and could not integrate it cleanly because the autoloading is broken due to the fix for PHP5.
Steps to Reproduce
Take any Symfony installation, composer-require this and try to use it inside a service. It basically doesn't work because the Formatter and Handler classes never end up in the classmap.
Theoretically, this should also fail to work with composer dump-autoload generated files (i.e. the standard autoloading method).
Expected Behaviour
This works with normal PSR-4 autoloading.
Your Environment
The text was updated successfully, but these errors were encountered: