Skip to content

ini_set('error_log' sets filepath outside open_basedir #6197

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

Open
mvorisek opened this issue May 1, 2025 · 2 comments
Open

ini_set('error_log' sets filepath outside open_basedir #6197

mvorisek opened this issue May 1, 2025 · 2 comments
Labels
type/bug Something is broken

Comments

@mvorisek
Copy link
Contributor

mvorisek commented May 1, 2025

Q A
PHPUnit version 12.1.0-now
PHP version unrelated
Installation Method Composer

Summary

introduced in #6127 & #6118

merged as 3f275eb

/cc @staabm

Current behavior

Time: 00:00.573, Memory: 8.00 MB
1 test triggered 1 PHP warning:
1) /builds/mvorisek/atk4-hintable/vendor/phpunit/phpunit/src/Framework/TestCase.php:1290
ini_set(): open_basedir restriction in effect. File() is not within the allowed path(s):
    (/builds/mvorisek/atk4-hintable:/tmp)
Triggered by:
* Mvorisek\Atk4\Hintable\Tests\Core\MethodTest::testMethodName
  /builds/mvorisek/atk4-hintable/tests/Core/MethodTest.php:13
OK, but there were issues!
Tests: 151, Assertions: 463, Warnings: 1.

How to reproduce

Run phpunit with open_basedir configured.

repro code: https://github.com/mvorisek/atk4-hintable-mirror/tree/dde63a7362f2aacacf1e91b8fda2ea6adcb0bcc9

(but it seems it is not related with https://github.com/mvorisek/atk4-hintable-mirror/blob/dde63a7362f2aacacf1e91b8fda2ea6adcb0bcc9/tests/Core/MethodTest.php#L13 specific test, the test name in the report is there as it is the 1st one executed)

Expected behavior

no error

@staabm
Copy link
Contributor

staabm commented May 10, 2025

Could you PR a small reproducer of the problem as PHPT test?

@mvorisek
Copy link
Contributor Author

@staabm can I have your review on #6208?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type/bug Something is broken
Projects
None yet
Development

No branches or pull requests

2 participants