简体   繁体   中英

Class 'PragmaRX\Tracker\Vendor\Laravel\ServiceProvider' not found

I had installed PragmaRx\\Tracker package several months ago into my project. I started to deleting the package from laravel project through following steps:

1. composer remove vendor/PragmaRx/Tracker
2. remove package name form composer.json file
3. removing package from provider and aliases list in config/app.php file
4. composer dump-autoload
5. composer update
6. also php artisan dump-autoload

I also tried a bunch of other ways to remove the package.

after removing the package I'm getting this error when I run any artisan command (even "php artisan serve" command):

In ProviderRepository.php line 208:
      Class 'PragmaRX\Tracker\Vendor\Laravel\ServiceProvider' not found

It's obvious that the package and its related files have been removed! but I couldn't find out the error's reason.

my laravel version is 5.5.4 .

any idea?

finally I found the error's reason.It's because of laravel cache!!

in one hand I couldn't run any artisan command including "php artisan config:cache" to clear laravel cache, in the other hand the cache was the error's reason.So at first I re-installed the pachage :

composer require PragmaRx/Tracker

then :

php artisan config:cache

and finally :

composer remove PragmaRx/Tracker

Done.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM