Export not working when using Auth0

I'm trying to export data, nothing fancy or complicated but I'm getting the following error
Auth0\Laravel\Guards\AuthenticationGuard::login(): Argument #1 ($credential) must be of type ?Auth0\Laravel\Entities\CredentialEntityContract, App\Models\User given, called in vendor/laravel/framework/src/Illuminate/Auth/AuthManager.php on line 339
Auth0\Laravel\Guards\AuthenticationGuard::login(): Argument #1 ($credential) must be of type ?Auth0\Laravel\Entities\CredentialEntityContract, App\Models\User given, called in vendor/laravel/framework/src/Illuminate/Auth/AuthManager.php on line 339
I'm using the Export builting action
Solution:
I ended up using your Excel Export plugin πŸ™‚ @Dennis Koch I commented out the lines that were failing and the file was being created and saving correctly but now the notifications were failing :/
Jump to solution
5 Replies
Dennis Koch
Dennis Kochβ€’5d ago
The rest of the auth is working fine? Because the error comes from Laravel's AuthManager not from Filament
Will πŸ‡¬πŸ‡Ή
Will πŸ‡¬πŸ‡ΉOPβ€’5d ago
Hey @Dennis Koch thanks for the reply. Everything is working correctly, It seems like the error is coming from ExportCsv from Filament. Here is more on the error
2025-05-28 11:24:28 Illuminate\Bus\ChainedBatch 1825 ....... RUNNING
2025-05-28 11:24:28 Illuminate\Bus\ChainedBatch 1825 ....... 64.62ms DONE
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\PrepareCsvExport 1826 ....... RUNNING
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\PrepareCsvExport 1826 ....... 37.53ms DONE
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\ExportCsv 1827 ....... RUNNING
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\ExportCsv 1827 ....... 86.10ms FAIL
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\ExportCompletion 1828 ....... RUNNING
2025-05-28 11:24:29 Filament\Actions\Exports\Jobs\ExportCompletion 1828 ....... 42.04ms DONE
2025-05-28 11:24:29 Filament\Notifications\DatabaseNotification 1829 ....... RUNNING
2025-05-28 11:24:29 Filament\Notifications\DatabaseNotification 1829 ....... 69.43ms DONE
2025-05-28 11:24:29 Filament\Notifications\Events\DatabaseNotificationsSent 1830 ....... RUNNING
2025-05-28 11:24:29 Filament\Notifications\Events\DatabaseNotificationsSent 1830 ....... 16.89ms DONE
2025-05-28 11:24:29 Filament\Actions\Exports\Jobs\CreateXlsxFile 1831 ....... RUNNING
2025-05-28 11:24:29 Filament\Actions\Exports\Jobs\CreateXlsxFile 1831 ....... 48.73ms DONE
2025-05-28 11:24:28 Illuminate\Bus\ChainedBatch 1825 ....... RUNNING
2025-05-28 11:24:28 Illuminate\Bus\ChainedBatch 1825 ....... 64.62ms DONE
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\PrepareCsvExport 1826 ....... RUNNING
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\PrepareCsvExport 1826 ....... 37.53ms DONE
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\ExportCsv 1827 ....... RUNNING
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\ExportCsv 1827 ....... 86.10ms FAIL
2025-05-28 11:24:28 Filament\Actions\Exports\Jobs\ExportCompletion 1828 ....... RUNNING
2025-05-28 11:24:29 Filament\Actions\Exports\Jobs\ExportCompletion 1828 ....... 42.04ms DONE
2025-05-28 11:24:29 Filament\Notifications\DatabaseNotification 1829 ....... RUNNING
2025-05-28 11:24:29 Filament\Notifications\DatabaseNotification 1829 ....... 69.43ms DONE
2025-05-28 11:24:29 Filament\Notifications\Events\DatabaseNotificationsSent 1830 ....... RUNNING
2025-05-28 11:24:29 Filament\Notifications\Events\DatabaseNotificationsSent 1830 ....... 16.89ms DONE
2025-05-28 11:24:29 Filament\Actions\Exports\Jobs\CreateXlsxFile 1831 ....... RUNNING
2025-05-28 11:24:29 Filament\Actions\Exports\Jobs\CreateXlsxFile 1831 ....... 48.73ms DONE
This is failing Filament\Actions\Exports\Jobs\ExportCsv here is more of the error
vendor/filament/actions/src/Exports/Jobs/ExportCsv.php:69
{
Filament\Actions\Exports\Jobs
\
ExportCsv->handle(): void
…
β€Ί if (method_exists(auth()->guard(), 'login')) {
β€Ί auth()->login($user);
β€Ί } else {
}
vendor/filament/actions/src/Exports/Jobs/ExportCsv.php:69
{
Filament\Actions\Exports\Jobs
\
ExportCsv->handle(): void
…
β€Ί if (method_exists(auth()->guard(), 'login')) {
β€Ί auth()->login($user);
β€Ί } else {
}
No description
Dennis Koch
Dennis Kochβ€’5d ago
Looking into the ExportCsv class, it tries to either resolve a Authenticatable class or defaults to App\Models\User model.
I think you have 2 options: Bind the Admin user to Authenticable but I am not sure how you'd bind Admin vs User based on context. Or you might need to replace the Export model with your own, but I haven't looked into that yet.
Solution
Will πŸ‡¬πŸ‡Ή
I ended up using your Excel Export plugin πŸ™‚ @Dennis Koch I commented out the lines that were failing and the file was being created and saving correctly but now the notifications were failing :/
Dennis Koch
Dennis Kochβ€’5d ago
Nice. Whatever works πŸ˜…

Did you find this page helpful?