php artisan event:list missing events When I run:
php artisan event:list
it lists my listeners but not the events.
The event "Registered" is listed and its listener "SendEmailVerificationNotification" is listed, but not the event I created only the listeners that I created are listed. I created one event and two listeners and the listeners are listed but not the event.
It all works though
+-----------------------------------+-------------------------------------------------------------+
| Event | Listeners |
+-----------------------------------+-------------------------------------------------------------+
| | App\Listeners\AwardAchievements
| | App\Listeners\SendSharableCoupon |
| Illuminate\Auth\Events\Registered | Illuminate\Auth\Listeners\SendEmailVerificationNotification |
+-----------------------------------+-------------------------------------------------------------+
I have a event App\Events\ProductPurchased
there is only a pipe it looks like there in place of the event class path?
Can you show us your EventServiceProvider.php file?
What terminal are you using?
My EventServiceProvider.php looks like this
protected $listen = [
Registered::class => [
SendEmailVerificationNotification::class,
],
Test::class => [
HandleClearResponseCache::class,
SendEmailVerificationNotification::class,
],
];
and php artisan event:list Gives me this https://cln.sh/GSgrPm
protected $listen = [
Registered::class => [
SendEmailVerificationNotification::class,
],
TestEvent::class => [
TestListenerOne::class,
TestListenerTwo::class,
],
];
+-----------------------------------+-------------------------------------------------------------+
| Event | Listeners |
+-----------------------------------+-------------------------------------------------------------+
| | App\Listeners\TestListenerOne
| | App\Listeners\TestListenerTwo |
| Illuminate\Auth\Events\Registered | Illuminate\Auth\Listeners\SendEmailVerificationNotification |
+-----------------------------------+-------------------------------------------------------------+
see the little pipe in place of the name which should be "TestEvent"
I am on windows using git bash and wamp server.
You can try with php artisan event:list --no-ansi this seems to be a git bash issue and not a Laravel specific issue
It is listing the one from vendor
here is powershel:
PS C:\wamp64\www\laravel> php artisan event:list
+-----------------------------------+-------------------------------------------------------------+
| Event | Listeners |
+-----------------------------------+-------------------------------------------------------------+
| | App\Listeners\TestListenerOne
| | App\Listeners\TestListenerTwo |
| Illuminate\Auth\Events\Registered | Illuminate\Auth\Listeners\SendEmailVerificationNotification |
+-----------------------------------+-------------------------------------------------------------+
PS C:\wamp64\www\laravel>
leme ssh onto my server to rule out wamp
The problem is the wamp server, It works properly on my local lamp server using git bash from my windows machine
Please sign in or create an account to participate in this conversation.