Describe the bug
composer install complains about non-compliant classes ("Deprecation Notice: Class insert\path\here does not comply with psr-4 autoloading standard").
Steps To Reproduce
Steps to reproduce the behavior:
composer installExpected behavior
I expect not to see a flood of deprecation warnings during installation.
Your Configuration (please complete the following information):
Additional context
Full list of deprecation warnings:
Class Tests\ConfigTest located in ./tests/Unit/ConfigTest.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:185
Class Tests\UrlTest located in ./tests/Unit/UrlTest.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:185
Class Tests\SocialAuthTest located in ./tests/Auth/SocialAuthTest.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:185
Class Tests\LdapTest located in ./tests/Auth/LdapTest.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:185
Class Tests\UserInviteTest located in ./tests/Auth/UserInviteTest.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:185
Class Tests\Saml2Test located in ./tests/Auth/Saml2Test.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:185
Class Tests\AuthTest located in ./tests/Auth/AuthTest.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:185
Class Tests\AttachmentTest located in ./tests/Uploads/AttachmentTest.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:185
Class Tests\RestrictionsTest located in ./tests/Permissions/RestrictionsTest.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:185
Class Tests\RolesTest located in ./tests/Permissions/RolesTest.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:185
Class Tests\UserProfileTest located in ./tests/User/UserProfileTest.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:185
Class Tests\UserPreferencesTest located in ./tests/User/UserPreferencesTest.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:185
Class Tests\ApiDocsTest located in ./tests/Api/ApiDocsTest.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:185
Class Tests\BooksApiTest located in ./tests/Api/BooksApiTest.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:185
Class Tests\ApiAuthTest located in ./tests/Api/ApiAuthTest.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:185
Class Tests\ApiConfigTest located in ./tests/Api/ApiConfigTest.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:185
Class Tests\ApiListingTest located in ./tests/Api/ApiListingTest.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:185
Class Tests\ExportTest located in ./tests/Entity/ExportTest.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:185
Class Tests\CommentSettingTest located in ./tests/Entity/CommentSettingTest.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:185
Class Tests\SortTest located in ./tests/Entity/SortTest.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:185
Class Tests\CommentTest located in ./tests/Entity/CommentTest.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:185
Class Tests\EntitySearchTest located in ./tests/Entity/EntitySearchTest.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:185
Class Tests\MarkdownTest located in ./tests/Entity/MarkdownTest.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:185
Class Tests\PageDraftTest located in ./tests/Entity/PageDraftTest.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:185
Class Tests\PageContentTest located in ./tests/Entity/PageContentTest.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:185
Class Tests\TagTest located in ./tests/Entity/TagTest.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:185
Class Tests\EntityTest located in ./tests/Entity/EntityTest.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:185
Class Tests\BookShelfTest located in ./tests/Entity/BookShelfTest.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:185
It appears the only classes affected are in the Tests namespace, so this probably won't affect actually running BookStack in production.
You sure you're on composer 1.9.3? I had to use the unreleased 1.10.0-RC build to get these warnings to show.
Either way, Thanks for reporting! Have assigned to be addressed for the next feature release.
We _should_ be on composer 1.9.3, since the PHP setup action we use (shivammathur/setup-php) "always" uses the latest version, per its documentation. The last workflow run log shows composer/composer 1.9.2 being installed during the composer install step, though. Not sure if related.
@dgw Ah, okay, thanks. Looks like that action may have been installing pre-releases up until two days ago:
https://github.com/shivammathur/setup-php/issues/192
@ssddanbrown Confirmed the version in install log is irrelevant. Forcing a new workflow run with the latest setup-php action (the repo needed a readme anyway 馃槈), I don't see the deprecation warnings from composer any more. Apologies for the wrong version info; next time I'll add a "Check composer version" step to the job before reporting!
Most helpful comment
You sure you're on composer
1.9.3? I had to use the unreleased1.10.0-RCbuild to get these warnings to show.Either way, Thanks for reporting! Have assigned to be addressed for the next feature release.