-
Notifications
You must be signed in to change notification settings - Fork 11.1k
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
OptimizeCommand is back #25498
Comments
The old one was gone for a good 7 months before (and deprecated 2 months before that) before the new command was introduced. Surely it wouldn't have been in anyone's deployment scripts and now suddenly causing an issue all of sudden. The new one just calls the caching commands in one go - for config and routes. If your routing isn't compatible with the route cache then just don't use the optimise command. |
The documentation states that you can't cache routes that utilize closures. So if you're using closure based routes, you'll get an error if you attempt to cache. |
It is not a problem for me not using it. As a matter of fact I don't use it and I don't need it. I somehow installed some package that wasn't really updated and was using that command, and noticed the LogicException throwing. Digging it deeper seems the Optimize command was not included in the 5.7.1 tag, and came back in 5.7.2 tag, and that was the only reason I opened this issue, not that I need something get fixed |
Hi there, Welcome to Laravel and we are glad to have you as part of the community. Unfortunately this GitHub area is not for ideas, suggestions etc. This is only for issues/bugs with the framework code itself. I will be closing your ticket here. You are able to open a ticket at https://github.com/laravel/ideas Alternatively you are able to open a PR using the Contributions guidelines: https://laravel.com/docs/5.7/contributions#which-branch If you feel I've closed this issue in error, please provide more information about how this is a framework issue, and I'll reopen the ticket. Thanks in advance. |
Laravel Optimize Command is back, and causing some problems (if called, it tries to cache routes and the ones that use Closures throw an LogicException (src/Illuminate/Routing/Route.php:880) )
#20851
The text was updated successfully, but these errors were encountered: