-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
artisan route:cache Unable to prepare route [api/v1] for serialization. Uses Closure. #10224
Comments
👋 Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it. We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can. |
You don't need to cache the routes. You can skip |
OK Thanks |
Reopening this, since it is a legitimate bug, just not one that breaks anything. |
I'm sorry, I think this can't be fixed without rewriting all of our existing routes. The Laravel documentation warns that this is not possible with routes using closures https://laravel.com/docs/6.x/deployment#optimizing-route-loading: which we use extensively. So, unfortunately, I don't think we can address this issue in short term... |
FYI, this is related to #11595, where we had done a lot of fixes. In Laravel 8, the closure isn't the issue anymore, but rather duplicate names for routes. |
Debug mode
Describe the bug
Unable to prepare route [api/v1] for serialization. Uses Closure.
Reproduction steps
Expected behavior
successfully
Screenshots
No response
Snipe-IT Version
5.3.0
Operating System
Centos7
Web Server
nginx
PHP Version
7.4.24
Operating System
No response
Browser
No response
Version
No response
Device
No response
Operating System
No response
Browser
No response
Version
No response
Error messages
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: