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

Could not process file, due to UrlGeneratorInterface not found. #691

Closed
biozshock opened this issue Dec 6, 2024 · 0 comments · Fixed by #692
Closed

Could not process file, due to UrlGeneratorInterface not found. #691

biozshock opened this issue Dec 6, 2024 · 0 comments · Fixed by #692

Comments

@biozshock
Copy link

Hello.

First of all thank you for the tool! Amazing.

Want to report a bug, where, rector can't seem to find it's bundled class RectorPrefix202411\Symfony\Component\Routing\Generator\UrlGeneratorInterface.

Stack trace:

[ERROR] Could not process "/var/www/code/rector-class-not-found/src/Check.php" file, due to:                           
         "System error: "Class "RectorPrefix202411\Symfony\Component\Routing\Generator\UrlGeneratorInterface" not found"
                                                                                                                        
         Stack trace:                                                                                                   
         #0                                                                                                             
         vendor/rector/rector/vendor/rector/rector-symfony/rules/Symfony26/Rector/MethodCall/RedirectToRouteRector.php(7
         4): Rector\Symfony\Symfony26\Rector\MethodCall\RedirectToRouteRector->isDefaultReferenceType()                 
         #1 vendor/rector/rector/src/Rector/AbstractRector.php(140):                                                    
         Rector\Symfony\Symfony26\Rector\MethodCall\RedirectToRouteRector->refactor()                                   
         #2 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(114):                          
         Rector\Rector\AbstractRector->enterNode()                                                                      
         #3 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(198):                          
         PhpParser\NodeTraverser->traverseNode()                                                                        
         #4 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(105):                          
         PhpParser\NodeTraverser->traverseArray()                                                                       
         #5 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(198):                          
         PhpParser\NodeTraverser->traverseNode()                                                                        
         #6 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(105):                          
         PhpParser\NodeTraverser->traverseArray()                                                                       
         #7 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(198):                          
         PhpParser\NodeTraverser->traverseNode()                                                                        
         #8 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(105):                          
         PhpParser\NodeTraverser->traverseArray()                                                                       
         #9 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(198):                          
         PhpParser\NodeTraverser->traverseNode()                                                                        
         #10 vendor/rector/rector/vendor/nikic/php-parser/lib/PhpParser/NodeTraverser.php(85):                          
         PhpParser\NodeTraverser->traverseArray()                                                                       
         #11 vendor/rector/rector/src/PhpParser/NodeTraverser/RectorNodeTraverser.php(47):                              
         PhpParser\NodeTraverser->traverse()                                                                            
         #12 vendor/rector/rector/src/Application/FileProcessor.php(113):                                               
         Rector\PhpParser\NodeTraverser\RectorNodeTraverser->traverse()                                                 
         #13 vendor/rector/rector/src/Application/ApplicationFileProcessor.php(184):                                    
         Rector\Application\FileProcessor->processFile()                                                                
         #14 vendor/rector/rector/src/Application/ApplicationFileProcessor.php(161):                                    
         Rector\Application\ApplicationFileProcessor->processFile()                                                     
         #15 vendor/rector/rector/src/Application/ApplicationFileProcessor.php(138):                                    
         Rector\Application\ApplicationFileProcessor->processFiles()                                                    
         #16 vendor/rector/rector/src/Console/Command/ProcessCommand.php(156):                                          
         Rector\Application\ApplicationFileProcessor->run()                                                             
         #17 vendor/rector/rector/vendor/symfony/console/Command/Command.php(327):                                      
         Rector\Console\Command\ProcessCommand->execute()                                                               
         #18 vendor/rector/rector/vendor/symfony/console/Application.php(960):                                          
         RectorPrefix202411\Symfony\Component\Console\Command\Command->run()                                            
         #19 vendor/rector/rector/vendor/symfony/console/Application.php(333):                                          
         RectorPrefix202411\Symfony\Component\Console\Application->doRunCommand()                                       
         #20 vendor/rector/rector/src/Console/ConsoleApplication.php(53):                                               
         RectorPrefix202411\Symfony\Component\Console\Application->doRun()                                              
         #21 vendor/rector/rector/vendor/symfony/console/Application.php(216):                                          
         Rector\Console\ConsoleApplication->doRun()                                                                     
         #22 vendor/rector/rector/bin/rector.php(130): RectorPrefix202411\Symfony\Component\Console\Application->run()  
         #23 vendor/rector/rector/bin/rector(5): require_once('...')                                                    
         #24 vendor/bin/rector(119): include('...')                                                                     
         #25 {main}". On line: 88 

And of course a minimal reproducible: https://github.com/biozshock/rector-class-not-found

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

Successfully merging a pull request may close this issue.

1 participant