mirror of
https://github.com/danog/psalm.git
synced 2024-11-30 04:39:00 +01:00
Improve the reported error when a worker crashes
This commit is contained in:
parent
0e23fab5d2
commit
eadf2f8492
@ -204,8 +204,9 @@ class Pool
|
||||
// Serialize this child's produced results and send them to the parent.
|
||||
$process_done_message = new ForkProcessDoneMessage($results ?: []);
|
||||
} catch (\Throwable $t) {
|
||||
// This can happen when developing Psalm from source without running `composer update`, or because of rare bugs in Psalm.
|
||||
/** @psalm-suppress MixedArgument on Windows, for some reason */
|
||||
$process_done_message = new ForkProcessErrorMessage($t->getMessage());
|
||||
$process_done_message = new ForkProcessErrorMessage($t->getMessage() . "\nStack trace in the forked worker:\n" . $t->getTraceAsString());
|
||||
}
|
||||
|
||||
$serialized_message = $task_done_buffer . base64_encode(serialize($process_done_message)) . "\n";
|
||||
|
Loading…
Reference in New Issue
Block a user