{"action":"created","issue":{"url":"https://api.github.com/repos/dunglas/DunglasActionBundle/issues/18","repository_url":"https://api.github.com/repos/dunglas/DunglasActionBundle","labels_url":"https://api.github.com/repos/dunglas/DunglasActionBundle/issues/18/labels{/name}","comments_url":"https://api.github.com/repos/dunglas/DunglasActionBundle/issues/18/comments","events_url":"https://api.github.com/repos/dunglas/DunglasActionBundle/issues/18/events","html_url":"https://github.com/dunglas/DunglasActionBundle/issues/18","id":142204147,"number":18,"title":"Command registration is broken with setter autowiring","user":{"login":"dunglas","id":57224,"avatar_url":"https://avatars.githubusercontent.com/u/57224?v=3","gravatar_id":"","url":"https://api.github.com/users/dunglas","html_url":"https://github.com/dunglas","followers_url":"https://api.github.com/users/dunglas/followers","following_url":"https://api.github.com/users/dunglas/following{/other_user}","gists_url":"https://api.github.com/users/dunglas/gists{/gist_id}","starred_url":"https://api.github.com/users/dunglas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dunglas/subscriptions","organizations_url":"https://api.github.com/users/dunglas/orgs","repos_url":"https://api.github.com/users/dunglas/repos","events_url":"https://api.github.com/users/dunglas/events{/privacy}","received_events_url":"https://api.github.com/users/dunglas/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/dunglas/DunglasActionBundle/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2016-03-20T20:52:13Z","updated_at":"2016-03-20T21:38:31Z","closed_at":null,"body":"With setter autowiring enabled (symfony/symfony#17608), command registration still fail:\r\n\r\n```\r\nMacBook-Pro-de-Kevin:symfony-standard dunglas$ bin/console c:c -vvv\r\n\r\n                                                                                                               \r\n  [Symfony\\Component\\DependencyInjection\\Exception\\RuntimeException]                                           \r\n  Unable to autowire argument index 0 ($code) of the method \"setCode\" for the service \"command.symfony\\bundle  \r\n  \\frameworkbundle\\command\\containerdebugcommand\". If this is an object, give it a type-hint. Otherwise, spec  \r\n  ify this argument's value explicitly.                                                                        \r\n                                                                                                               \r\n\r\nException trace:\r\n () at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php:116\r\n Symfony\\Component\\DependencyInjection\\Compiler\\AutowirePass->autowireMethod() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php:83\r\n Symfony\\Component\\DependencyInjection\\Compiler\\AutowirePass->completeDefinition() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/Compiler/AutowirePass.php:40\r\n Symfony\\Component\\DependencyInjection\\Compiler\\AutowirePass->process() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/Compiler/Compiler.php:107\r\n Symfony\\Component\\DependencyInjection\\Compiler\\Compiler->compile() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/DependencyInjection/ContainerBuilder.php:545\r\n Symfony\\Component\\DependencyInjection\\ContainerBuilder->compile() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php:477\r\n Symfony\\Component\\HttpKernel\\Kernel->initializeContainer() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/HttpKernel/Kernel.php:117\r\n Symfony\\Component\\HttpKernel\\Kernel->boot() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Bundle/FrameworkBundle/Console/Application.php:68\r\n Symfony\\Bundle\\FrameworkBundle\\Console\\Application->doRun() at /Users/dunglas/workspace/symfony-standard/vendor/symfony/symfony/src/Symfony/Component/Console/Application.php:117\r\n Symfony\\Component\\Console\\Application->run() at /Users/dunglas/workspace/symfony-standard/bin/console:29\r\n```\r\n\r\nIMO opinion, using a different directory than `Command` for autoregistered commands would be safer.\r\n\r\nping @Ener-Getick, what do you think?"},"comment":{"url":"https://api.github.com/repos/dunglas/DunglasActionBundle/issues/comments/199033064","html_url":"https://github.com/dunglas/DunglasActionBundle/issues/18#issuecomment-199033064","issue_url":"https://api.github.com/repos/dunglas/DunglasActionBundle/issues/18","id":199033064,"user":{"login":"dunglas","id":57224,"avatar_url":"https://avatars.githubusercontent.com/u/57224?v=3","gravatar_id":"","url":"https://api.github.com/users/dunglas","html_url":"https://github.com/dunglas","followers_url":"https://api.github.com/users/dunglas/followers","following_url":"https://api.github.com/users/dunglas/following{/other_user}","gists_url":"https://api.github.com/users/dunglas/gists{/gist_id}","starred_url":"https://api.github.com/users/dunglas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dunglas/subscriptions","organizations_url":"https://api.github.com/users/dunglas/orgs","repos_url":"https://api.github.com/users/dunglas/repos","events_url":"https://api.github.com/users/dunglas/events{/privacy}","received_events_url":"https://api.github.com/users/dunglas/received_events","type":"User","site_admin":false},"created_at":"2016-03-20T21:38:31Z","updated_at":"2016-03-20T21:38:31Z","body":"It would be nice if you have the time to do it."}}