F
Filament3mo ago
Matt

Creating Laravel Sanctum Tokens

When I try to create a laravel sanctum Personal Access Token from a filament action, my panel is no longer accessible (500 error) until I delete that users session. Only my filament panel is affected. There is no error logged in Laravel or nginx on my local development environment (Laravel Herd) I'm using Auth::user()->createToken() to create my access tokens. I have created a fresh laravel project with a fresh install of Filament and I have the exact same issue. If I create a token from a route not related to Filament, it does not affect my session. Does anyone have any idea what I'm doing wrong?
3 Replies
toeknee
toeknee3mo ago
Enable debug mode? Install Sentry, 500 error is a coding error and should trigger an exception or sorts. If you get a laravel 500 error then it should be logged, else check the php error_log.
Matt
MattOP3mo ago
Debug mode is enabled. I’m getting an nginx 500 error but no nginx error is logged.
toeknee
toeknee3mo ago
500 nginx is probably a 500 php error triggered by php returning the 500 nginx reponds with it too, I would suggest running it through xdebug, check sentry and maybe telescope.

Did you find this page helpful?