Closed philip1337 closed 3 years ago
Adding a namespace to the proxy class files might fix it. With the downside of having all three classes at each namespace.
The other option is to break the Pear_CHAP file into three classes and set the namespace correctly. Which would make updating harder, but not sure how much updating is going to happen :D
@philip1337 Do you recall what version of composer you were using at the time of the update?
I can't reproduce that warning with version 1.10.5. I also tried the 2.0 dev snapshot and it adds the Pear Crypt classes to the psr-0 autoloader and the code runs fine (and I can see it properly added to the autoloader).
It is showing for me in Composer version 1.10.6 2020-05-06 10:28:10
With dapphp/radius 2.5.4
PHP 7.4.5
@dapphp It was the newest at this time.
I think we can relate to @HenkPoley his version here. I was running it on php 7.3.11.
Same here
$ php -v
PHP 7.2.31
$ composer --version
Composer version 1.10.8 2020-06-24 21:23:30
$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Nothing to install or update
Generating optimized autoload files
Deprecation Notice: Class Crypt_CHAP_MD5 located in ./vendor/dapphp/radius/lib/Pear_CHAP.php does not comply with psr-0 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 Crypt_CHAP_MSv1 located in ./vendor/dapphp/radius/lib/Pear_CHAP.php does not comply with psr-0 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 Crypt_CHAP_MSv2 located in ./vendor/dapphp/radius/lib/Pear_CHAP.php does not comply with psr-0 autoloading standard. It will not autoload anymore in Composer v2.0. in phar:///usr/local/bin/composer/src/Composer/Autoload/ClassMapGenerator.php:201
> Illuminate\Foundation\ComposerScripts::postAutoloadDump
1954c34c may have fixed this, or this is no longer an issue. Composer 2.0.8 doesn't show this error running on PHP 7.2, 7.3, or 7.4.
If anyone is still having issues with this please re-open or file a new bug.
Thank you!
$ composer -V
Composer version 2.0.8 2020-12-03 17:20:38
$ php -v
PHP 7.4.13 (cli) (built: Dec 19 2020 07:20:29) ( NTS )
Copyright (c) The PHP Group
Zend Engine v3.4.0, Copyright (c) Zend Technologies
$ composer create-project laravel/laravel test
$ cd test
$ composer require dapphp/radius
Using version ^2.5 for dapphp/radius
./composer.json has been updated
Running composer update dapphp/radius
Loading composer repositories with package information
Updating dependencies
Lock file operations: 1 install, 0 updates, 0 removals
- Locking dapphp/radius (2.5.4)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
- Installing dapphp/radius (2.5.4): Extracting archive
Generating optimized autoload files
Class Crypt_CHAP_MD5 located in ./vendor/dapphp/radius/lib/Pear_CHAP.php does not comply with psr-0 autoloading standard. Skipping.
Class Crypt_CHAP_MSv1 located in ./vendor/dapphp/radius/lib/Pear_CHAP.php does not comply with psr-0 autoloading standard. Skipping.
Class Crypt_CHAP_MSv2 located in ./vendor/dapphp/radius/lib/Pear_CHAP.php does not comply with psr-0 autoloading standard. Skipping.
There hasn't been any release in 2 years. It's only fixed in dev-master: https://packagist.org/packages/dapphp/radius#2.5.4
(👉 please roll a new release 🙏)
@Jellyfrog for Laravel and problem with psr-0, that was my solution:
Add this on composer.json under autolaod for psr-4 / classmap: "classmap": [ "vendor/dapphp/radius" ]
During a new composer update I got the following notification:
I saw the same issue got fixed 2 years ago. Composer 2.0 is not gonna support the fix anymore.