Chris vCB
Chris vCB

Reputation: 1053

Laravel error in /bootstrap/start.php: \Illuminate\Foundation\Application not found

So, I installed Laravel on a dev server (php5.5.3, standard installation, mcrypt installed), and I get the following error message:

Fatal error: Class 'Illuminate\Foundation\Application' not found in /[path_to_laravel_app]/bootstrap/start.php on line 14

Quite odd, and I haven't seen a solution to this file, although I've seen plenty of similar errors. Any advice welcome. Thanks!

Upvotes: 9

Views: 22346

Answers (5)

Majbah Habib
Majbah Habib

Reputation: 8558

Just Run the command

composer install --no-scripts

Or,

composer update --no-scripts

Upvotes: 1

Jnanaranjan
Jnanaranjan

Reputation: 1322

Run this command:

composer update --no-scripts

In my case I have added another required package(Guzzle) in the compser.json file separately(in the last line but it should be after the laravel package line) and updated the compsoser and came across this issue.

I have checked and my vendor/laravel folder has gone. That was preventing me to run any artisian command.

So "--no-scripts" worked for me as it prevents any scripts to be included before executing artisan.

You can use another method in case you are having issues.

  1. Install another raw laravel and copy all the files from the vendor file to your old repostory.
  2. Change permission of storage and bootstrap folder to 775 or 777.
  3. Delete everything in the session and view folder of storage/framework

Upvotes: 8

Al-Punk
Al-Punk

Reputation: 3669

Correct the composer.json. This might happen after you have added a new package configuration by dublicating the require tag.

Do not create yet another

require: {
     ..
    }

use the previous defined one.

Then follow the accepted answer to re-install the packages.

Upvotes: 2

Dumindu Perera
Dumindu Perera

Reputation: 1649

Double check your composer.json file. If you have error on "require": section this error will occur.

Just restore a previous version of composer.json file and run composer update.

Upvotes: 0

Sam
Sam

Reputation: 20486

/bootstrap/start.php is created after composer install by running Laravel's php artisan optimize. I've had a lot of issues on this during upgrades of Laravel, but removing /bootstrap/start.php, composer.lock, and the vendor directory and re-running composer install should fix this issue.

Upvotes: 16

Related Questions