You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi there, I am currently working on a project, where I stumbled across a segmentation fault, which I then tracked down to be a subset of the combination of the factors sail, xdebug develop mode and throwing a exception inside a Http::fake callback.
Running the tests without laravel sail and without xdebug develop mode (both at once, I unfortunately do not have a php runtime with xdebug on my wsl machine) did not cause the segmentation fault to occur.
In the original project I could work around this issue by introducing a middleware that handles the exceptions for me instead of throwing them in the Http::fake callback, if this information is for any good.
Am I doing something wrong with my laravel sail configuration?
Thanks
Steps To Reproduce
I unfortunately didnt now about laravel new bug-report before starting my test repo, so I started a regular laravel application using the installer.
It's an Xdebug bug probably as downgrading to Xdebug 3.2.2 worked for us. We're using a custom Dockerfile where we install everything ourselves, though, so not sure how to fix this with Sail.
Edit: By the way, for us it also always happened as soon as there was one breakpoint in the code.
Sail Version
1.31.3
Laravel Version
11.22.0
PHP Version
8.3.11
Operating System
Windows (WSL)
OS Version
23H2 OS Build 22631.4169
Description
Xdebug Version: 3.3.2
Docker Version: 27.1.1, build 6312585
WSL-Version (
wsl --version
):Hi there, I am currently working on a project, where I stumbled across a segmentation fault, which I then tracked down to be a subset of the combination of the factors sail, xdebug develop mode and throwing a exception inside a Http::fake callback.
After tracking it down as far as I can, I made an example repo with minimal changes to reproduce the issue: https://github.com/michiruf/laravel-sail-xdebug-segmentation-fault
The test that causes the exception can be found here: https://github.com/michiruf/laravel-sail-xdebug-segmentation-fault/blob/master/tests/Feature/SegmentationFaultTest.php and there is also a test.sh that executes the tests 100 times to get a better overview how often this will occur.
Running the tests without laravel sail and without xdebug develop mode (both at once, I unfortunately do not have a php runtime with xdebug on my wsl machine) did not cause the segmentation fault to occur.
In the original project I could work around this issue by introducing a middleware that handles the exceptions for me instead of throwing them in the Http::fake callback, if this information is for any good.
Am I doing something wrong with my laravel sail configuration?
Thanks
Steps To Reproduce
I unfortunately didnt now about
laravel new bug-report
before starting my test repo, so I started a regular laravel application using the installer.vendor/bin/sail up -d
vendor/bin/sail test
test.sh
and start 100 iterations executing thetest.sh
in the repoMy last run with 1000 iterations:
The text was updated successfully, but these errors were encountered: