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
Fatal error when phpinfo is disabled #5709
Comments
This bug report is missing a link to reproduction on phpstan.org. It will most likely be closed after manual review. |
Sounds like you should report it to react/child-process |
Thanks. Created a report to react/child-process |
Updated react/child-process here: phpstan/phpstan-src@ca3aad0 Feel free to test dev-master of phpstan/phpstan. 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
If you put the phpinfo function in disabled_functions and try to analyze phpstan with php8.0, it will throw the next error
PHP Fatal error: Uncaught Error: Call to undefined function phpinfo() in phar:.../vendor/phpstan/phpstan/phpstan.phar/vendor/react/child-process/src/Process.php:373
There is the next code where it throw error attempting to call phpinfo function
In the comments to the method there is a reference to a similar method from the Symfony class, where the disabled
phpinfo
state is provided https://github.com/symfony/symfony/blob/5.4/src/Symfony/Component/Process/Process.php#L1377Since
phpinfo
is disabled for security purposes in my case, is it possible to add this behavior to phpstan?Ready to send a Pull Request
Thank you for your time, checking this issue.
Code snippet that reproduces the problem
Expected output
No fatal error
The text was updated successfully, but these errors were encountered: