-
Notifications
You must be signed in to change notification settings - Fork 533
Treat Redis::connect as non-deterministic #4318
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
Conversation
- I'd say connect method has to change instead, that will take care of invalidating remembered isConnected when called.
- You edited the correct file but you also need to run bin/ script to regenerate the metadats file that doesn't have "original" in its name.
If you're interested, you can check out this part of my talk about pure/impure and so on here: https://youtu.be/AFjr3RlDOZQ?si=dp_XJWfenGJBRQhp (from about 28:50 timestamp)
Makes sense. Please suggest how can I test this.
you can add a new testXX
method into tests/PHPStan/Rules/TooWideTypehints/TooWidePropertyTypeRuleTest.php
and put your code from https://phpstan.org/r/1695567f-4869-428f-8cb6-fdd8cb147be1 into the tests data/
directory.
then assert no errors
similar to
phpstan-src/tests/PHPStan/Rules/TooWideTypehints/TooWidePropertyTypeRuleTest.php
Lines 104 to 107 in 99efae3
c7c8c89
to
21f4d32
Compare
I've added the test but I couldn't reproduce the original behavior before this change.
Needs $this->reportTooWideBool = true;
in the rule test class
Thanks, hallelujah!
don't get confused by the CI results.. we currently investigate spurious CI errors
1de1dad
into
phpstan:2.1.x
Thank you!
Uh oh!
There was an error while loading. Please reload this page.
Fixes https://phpstan.org/r/1695567f-4869-428f-8cb6-fdd8cb147be1.