-
Notifications
You must be signed in to change notification settings - Fork 11.6k
Comparing changes
Open a pull request
base repository: laravel/framework
base: 12.x
head repository: laravel/framework
compare: improve-broadcaster-error
- 7 commits
- 2 files changed
- 3 contributors
Commits on Oct 4, 2025
-
[12.x] Improve BroadcastManager error messages when trying to get a B…
…roadcaster Previously, when a broadcaster driver failed to initialize, the error message would only show the underlying exception without indicating which broadcasting connection configuration was responsible, and it was hard to identify it was actually coming from a broadcaster. Missing to provide a value for REVERB_APP_KEY, REVERB_APP_ID or REVERB_APP_SECRET would throw an error such as `TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given` and it would occur after running `composer install`, `php artisan optimize` or any command that would cause the broadcasting to be booted. This change wraps driver creation in a try-catch block that throws a BroadcastException with the connection name, making it immediately clear where the error is coming from and which configuration needs to be fixed. Before: > TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given After: > BroadcastException: Failed to create broadcaster for connection "terminal" with error: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given
Configuration menu - View commit details
-
Copy full SHA for a5a2b04 - Browse repository at this point
Copy the full SHA a5a2b04View commit details -
[12.x] Improve BroadcastManager error messages when trying to get a B…
…roadcaster Previously, when a broadcaster driver failed to initialize, the error message would only show the underlying exception without indicating which broadcasting connection configuration was responsible, and it was hard to identify it was actually coming from a broadcaster. Missing to provide a value for REVERB_APP_KEY, REVERB_APP_ID or REVERB_APP_SECRET would throw an error such as `TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given` and it would occur after running `composer install`, `php artisan optimize` or any command that would cause the broadcasting to be booted. This change wraps driver creation in a try-catch block that throws a BroadcastException with the connection name, making it immediately clear where the error is coming from and which configuration needs to be fixed. Before: > TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given After: > BroadcastException: Failed to create broadcaster for connection "my-connection" with error: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given
Configuration menu - View commit details
-
Copy full SHA for a3d3a0e - Browse repository at this point
Copy the full SHA a3d3a0eView commit details -
[12.x] Improve BroadcastManager error messages when trying to get a B…
…roadcaster Previously, when a broadcaster driver failed to initialize, the error message would only show the underlying exception without indicating which broadcasting connection configuration was responsible, and it was hard to identify it was actually coming from a broadcaster. Missing to provide a value for REVERB_APP_KEY, REVERB_APP_ID or REVERB_APP_SECRET would throw an error such as `TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given` and it would occur after running `composer install`, `php artisan optimize` or any command that would cause the broadcasting to be booted. This change wraps driver creation in a try-catch block that throws a BroadcastException with the connection name, making it immediately clear where the error is coming from and which configuration needs to be fixed. Before: > TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given After: > BroadcastException: Failed to create broadcaster for connection "my-connection" with error: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given
Configuration menu - View commit details
-
Copy full SHA for d7b38f6 - Browse repository at this point
Copy the full SHA d7b38f6View commit details -
[12.x] Improve BroadcastManager error messages when trying to get a B…
…roadcaster Previously, when a broadcaster driver failed to initialize, the error message would only show the underlying exception without indicating which broadcasting connection configuration was responsible, and it was hard to identify it was actually coming from a broadcaster. Missing to provide a value for REVERB_APP_KEY, REVERB_APP_ID or REVERB_APP_SECRET would throw an error such as `TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given` and it would occur after running `composer install`, `php artisan optimize` or any command that would cause the broadcasting to be booted. This change wraps driver creation in a try-catch block that throws a BroadcastException with the connection name, making it immediately clear where the error is coming from and which configuration needs to be fixed. Before: > TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given After: > BroadcastException: Failed to create broadcaster for connection "my-connection" with error: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given
Configuration menu - View commit details
-
Copy full SHA for 23be9ad - Browse repository at this point
Copy the full SHA 23be9adView commit details -
[12.x] Improve BroadcastManager error messages when trying to get a B…
…roadcaster Previously, when a broadcaster driver failed to initialize, the error message would only show the underlying exception without indicating which broadcasting connection configuration was responsible, and it was hard to identify it was actually coming from a broadcaster. Missing to provide a value for REVERB_APP_KEY, REVERB_APP_ID or REVERB_APP_SECRET would throw an error such as `TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given` and it would occur after running `composer install`, `php artisan optimize` or any command that would cause the broadcasting to be booted. This change wraps driver creation in a try-catch block that throws a BroadcastException with the connection name, making it immediately clear where the error is coming from and which configuration needs to be fixed. Before: > TypeError: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given After: > BroadcastException: Failed to create broadcaster for connection "my-connection" with error: Pusher\Pusher::__construct(): Argument #3 ($app_id) must be of type string, null given Testing using the LogBroadcaster since it is always available, while Pusher\Pusher is not.
Configuration menu - View commit details
-
Copy full SHA for 94cb66c - Browse repository at this point
Copy the full SHA 94cb66cView commit details
Commits on Oct 6, 2025
-
Configuration menu - View commit details
-
Copy full SHA for 8284a89 - Browse repository at this point
Copy the full SHA 8284a89View commit details -
Configuration menu - View commit details
-
Copy full SHA for 33d7804 - Browse repository at this point
Copy the full SHA 33d7804View commit details
This comparison is taking too long to generate.
Unfortunately it looks like we can’t render this comparison for you right now. It might be too big, or there might be something weird with your repository.
You can try running this command locally to see the comparison on your machine:
git diff 12.x...improve-broadcaster-error