-
Notifications
You must be signed in to change notification settings - Fork 57
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
Class 'Nette\Utils\Strings' not found possible problem with phpcs 3.2.3 ? #83
Comments
Hi, is Is |
Hi thanks for the reply and sorry for the delay.
What do you mean exactly? If I remove the rules
Phpcs works as expected. You can view the file here https://github.com/widoz/unprefix/blob/refactor-php7/phpcs.xml |
Hi @TomasVotruba it's me again, Sorry for the double reply but I guess I found the problem. I don't know exactly where could be in terms of line of codes but using the latest version of phpcs seems causing the issue. I switched to the latest version for 3.2.x and phpcs is able to work correctly without problems. |
Hey, that's great to hear! I tried to reproduce the issue and find myself stuck with autoloading problems. That's why I prefer ECS, where these problems doesn't exist. I'm glad it works 👍 |
I always get this when trying to run
phpcs
.I read the code and seems everything ok but the class
Strings
doesn't exists.Error: Class 'Nette\Utils\Strings' not found in /Users/user/Sites/sniffs/phpcs-calisthenics-rules/src/ObjectCalisthenics/Helper/Naming.php on line 43
Call Stack:
0.0006 392504 1. {main}() /usr/local/bin/phpcs.phar:0
0.0057 743384 2. PHP_CodeSniffer\Runner->runPHPCS() /usr/local/bin/phpcs.phar:6
0.1221 8372216 3. PHP_CodeSniffer\Runner->run() phar:///usr/local/bin/phpcs.phar/src/Runner.php:2
0.1291 8898144 4. PHP_CodeSniffer\Runner->processFile() phar:///usr/local/bin/phpcs.phar/src/Runner.php:2
0.1291 8898144 5. PHP_CodeSniffer\Files\LocalFile->process() phar:///usr/local/bin/phpcs.phar/src/Runner.php:2
0.1291 8898144 6. PHP_CodeSniffer\Files\LocalFile->process() phar:///usr/local/bin/phpcs.phar/src/Files/LocalFile.php:2
0.1516 9349616 7. ObjectCalisthenics\Sniffs\NamingConventions\ElementNameMinimalLengthSniff->process() phar:///usr/local/bin/phpcs.phar/src/Files/File.php:2
0.1521 9356928 8. ObjectCalisthenics\Helper\Naming::getElementName() /Users/user/Sites/sniffs/phpcs-calisthenics-rules/src/ObjectCalisthenics/Sniffs/NamingConventions/ElementNameMinimalLengthSniff.php:39
The text was updated successfully, but these errors were encountered: