Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

ruben_maxi's avatar

Livewire/Filament Pest test causing SIGSEGV error

I’m running into an issue when executing the following test:

it('can render the platforms page', function () { Livewire::test(ShowPlatforms::class) ->assertStatus(200); });

The process ends with:

Process finished with exit code 139 (interrupted by signal 11: SIGSEGV)

Interestingly, tests without Livewire/Filament work fine, for example:

it('can render the dashboard page', function () { $response = $this->get('/app/dashboard'); $response->assertStatus(200); });

I’m using the latest versions of Filament and Livewire:

filament: 4.0.0 beta-23

livewire: 3.6.4

This is on Laravel 12 with the Livewire starter kit.

Do you have any ideas on what might be causing this or how I could debug it?

Thanks in advance for your help!

0 likes
1 reply
LaryAI's avatar
Level 58

A SIGSEGV (segmentation fault) is a low-level crash, usually caused by a native extension (like PHP, Xdebug, or a PHP extension), not by PHP code itself. This is rare in Laravel/Pest/Livewire/Filament, but here are some steps to debug and resolve the issue:

1. Check for Incompatible Extensions

  • Xdebug is a common culprit. Try disabling it and rerunning your tests:
php -dxdebug.mode=off vendor/bin/pest
  • Also, check for other extensions like pcov, opcache, or any custom PHP extensions.

2. Update Dependencies

  • Since you’re using beta versions, make sure all dependencies are compatible and up-to-date:
composer update
  • Check for any open issues on Filament and Livewire repositories regarding segmentation faults.

3. Check for PHP Version Compatibility

  • Ensure your PHP version is compatible with Filament 4 and Livewire 3.6.4. Sometimes, bleeding-edge features or bugs in PHP itself can cause segmentation faults.

4. Simplify the Test

  • Try rendering a very basic Livewire component to see if the issue is with your specific component or with Livewire in general:
it('can render a basic livewire component', function () {
    Livewire::test(\App\Http\Livewire\SomeBasicComponent::class)
        ->assertStatus(200);
});
  • If this works, the issue may be in your ShowPlatforms component (e.g., infinite recursion, heavy constructor logic, or incompatible traits).

5. Check for Circular Dependencies

  • Sometimes, a circular dependency in service providers or Livewire components can cause a crash. Review your ShowPlatforms component for anything unusual.

6. Run with More Memory

  • If your system is low on memory, PHP may crash. Try increasing the memory limit:
php -d memory_limit=1G vendor/bin/pest

7. Debug with GDB (Advanced)

  • If you’re comfortable, you can run PHP under gdb to get a stack trace:
gdb --args php vendor/bin/pest
# Then type 'run' and after the crash, 'bt' for a backtrace.

8. Try Pest Without Parallel

  • If you’re running Pest in parallel mode, try disabling it:
vendor/bin/pest --parallel=1

Example: Minimal Test

it('can render the platforms page', function () {
    Livewire::test(\App\Livewire\ShowPlatforms::class)
        ->assertStatus(200);
});

If this still causes a segmentation fault, try commenting out logic in ShowPlatforms until the test passes, to isolate the issue.


Summary

  • Disable Xdebug and other extensions.
  • Update all dependencies.
  • Test with a minimal Livewire component.
  • Check for circular dependencies or heavy logic in your component.
  • Increase PHP memory limit.
  • Check compatibility of PHP version.
  • Search for similar issues on GitHub.

If none of these steps resolve the issue, please provide the code for your ShowPlatforms component and any relevant service providers for further debugging.

Please or to participate in this conversation.