Please provide a valid cache path.

InvalidArgumentException in Compiler.php: Please provide a valid cache path.

Explanation

Laravel has changed cache path across Laravel versions. It's possible your application is missing one of these folders or references one of the old paths.

Solution

There are several options which may resolve this issue. Start by trying the following common solutions:

  • Ensure the bootstrap/cache folder exists.
  • Ensure the storage folder contains the correct subfolders for your Laravel version (e.g. app, framework, logs).
  • Remove your config and application cache by running artisan cache:clear and artisan config:clear.
  • If artisan does not run, manually clear your cache by removing any PHP file under the bootstrap/cache folder.

← Back to the knowledge base

Did this solve the error? Give us a shout out on Twitter. If not, email support for help.

Sign in with any of the following services to connect Shift with your Laravel project.


Don't use one of these services?

Temporarily push your project to a free, private repository on one of these cloud-based services or upgrade your project locally with Shift for Docker.