4

I installed via composer the Guzzle and i received this error,

> @php artisan package:discover
PHP Fatal error:  Uncaught Error: Class 'Illuminate\Foundation\Application' not found in /home/vagrant/PROJ/memo/laravel_project/bootstrap/app.php:14
Stack trace:
#0 /home/vagrant/PROJ/memo/laravel_project/artisan(20): require_once()
#1 {main}
  thrown in /home/vagrant/PROJ/memo/laravel_project/bootstrap/app.php on line 14

Fatal error: Uncaught Error: Class 'Illuminate\Foundation\Application' not found in /home/vagrant/PROJ/memo/laravel_project/bootstrap/app.php:14
Stack trace:
#0 /home/vagrant/PROJ/memo/laravel_project/artisan(20): require_once()
#1 {main}
  thrown in /home/vagrant/PROJ/memo/laravel_project/bootstrap/app.php on line 14
Script @php artisan package:discover handling the post-autoload-dump event returned with error code 255

this was working before, and now i checked the DIR path and it's all ok. I also tried composer dump-autoload, composer update, removing composer.lock and vendor, composer install

BLDD
  • 483
  • 2
  • 8
  • 14

2 Answers2

18

Delete vendor folder and composer.lock.

After that

composer install

then

composer update --no-scripts

Try this, this will solve your error. Note: Please make sure you have all packages in composer.json.

CaseyB
  • 4,245
  • 1
  • 16
  • 10
jack
  • 589
  • 8
  • 22
3

Running composer require laravel/framework solved the problem in my own case. Answering in case someone googles the same problem and this page comes up

aiweb14
  • 31
  • 1