@pushpak1300 merged PR #785 into laravel/boost, fixing two crash modes that hit the boost:add command when downloading skills with a large number of files.
boost:add uses Http::pool() to fire all file download requests concurrently. When a skill has many files, GitHub's CDN starts refusing connections under load, responding with cURL error 7. The resulting ConnectionException ends up sitting in the responses array as a raw exception object, and calling ->failed() on it throws a fatal error instead of returning a boolean.
A second failure mode comes from Guzzle itself. When multiple promises are rejected concurrently, the pool's internal state can become corrupted, surfacing as a LogicException that also takes down the command.
Neither failure was caught or handled, so both paths resulted in an unhandled crash with no useful output to the user.
The fix properly catches both exception types when iterating over pool responses, rather than assuming every entry in the responses array is a well-formed Response object.
1// Before: calling ->failed() on a ConnectionException throws a fatal error 2foreach ($responses as $response) { 3 if ($response->failed()) { 4 // handle failure 5 } 6} 7 8// After: exceptions in pool responses are caught and handled explicitly 9foreach ($responses as $response) {10 if ($response instanceof \Illuminate\Http\Client\ConnectionException) {11 // handle connection failure from CDN rate limiting12 continue;13 }14 15 if ($response instanceof \LogicException) {16 // handle Guzzle promise state corruption17 continue;18 }19 20 if ($response->failed()) {21 // handle HTTP-level failure22 }23}
The PR also uses the concurrency polyfill to keep the behavior consistent on Laravel 11, where the pool concurrency API differs slightly.
If your project uses boost:add to pull in skills with more than a handful of files, this crash was likely reproducible under normal conditions, not just edge cases. GitHub's CDN rate limiting is aggressive enough that concurrent pool requests hit it reliably. Pulling the latest laravel/boost picks up this fix automatically.
If you enjoyed this article, please consider supporting our work for as low as $5 / month.
Sponsor
Written by
Writing and maintaining @LaravelMagazine. Host of "The Laravel Magazine Podcast". Pronouns: vi/vim.
Get latest news, tutorials, community articles and podcast episodes delivered to your inbox.