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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Reflection issue with bleeding edge rules in 1.6 #7112
Comments
This bug report is missing a link to reproduction at phpstan.org/try. It will most likely be closed after manual review. |
i have the similar issue and i have to add the error to ignore list: |
see https://github.com/calvera/phpstan-bug ... run |
@calvera This class is not reachable via the configured PSR-4 autoloading. A piece of code like this will cause PHPStan to crash with an unknown class too: <?php
use Symfony\Component\Validator\Test\ConstraintViolationAssertion;
require_once __DIR__ . "/vendor/autoload.php";
$a = new ConstraintViolationAssertion(); So I consider this a Symfony quirk. You can fix this for yourself with any method mentioned here https://phpstan.org/user-guide/discovering-symbols, or you can send a PR to Symfony so that it's fixed for everyone. |
@ondrejmirtes I have the feeling that my initial report has nothing to do with @calvera issue |
@kevinpapst Yes, it doesn't. Yours is fixed now: ondrejmirtes/BetterReflection@72bb305 + reproduction 17b309a |
Damn, your super-power is awesome: fixing bugs with the speed of light ... over and over again, very much appreciated 馃憤 I know this question is annoying, but I'd like to stick with enabled bleedingEdge rules and therefor I have to ask: |
Yes, later today :) |
@calvera I managed to fix your issue: phpstan/phpstan-src@e40474b No extra configuration will be needed in PHPStan 1.6.6 and |
great! thanks |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Bug report
After upgrading my composer packages, my CI started failing.
This is expected and appreciated if a new phpstan release was included 馃榿 but in this case it seems to be a false-negative.
EDIT:
I am running a Symfony project and I see dozens of errors like this:
I think the error is raised is in every class where a EventDispatcher is constructor injected.
I am not
use
ing this class in my code and therefor don't mention it in my composer require section, the only place I can see it being used is in Symfony EventDispatcher, you know the code:Did PHPStan help you today? Did it make you happy in any way?
Always makes me happy :) that's why I am using it in every project.
The text was updated successfully, but these errors were encountered: