0

After upgrading to php8, I now encounter an issue when running any composer command (composer, install, or composer update). When I do, I get this error:

./composer.json has been updated
Running composer update unicodeveloper/laravel-paystack
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - laravel/framework is locked to version v7.28.0 and an update of this package was not requested.
    - laravel/framework v7.28.0 requires php ^7.2.5 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 2
    - laravel/tinker is locked to version v2.4.2 and an update of this package was not requested.
    - laravel/tinker v2.4.2 requires php ^7.2 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 3
    - laravel/ui is locked to version v2.2.1 and an update of this package was not requested.
    - laravel/ui v2.2.1 requires php ^7.2.5 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 4
    - livewire/livewire is locked to version v1.3.3 and an update of this package was not requested.
    - livewire/livewire v1.3.3 requires php ^7.1.3 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 5
    - facade/ignition is locked to version 2.3.7 and an update of this package was not requested.
    - facade/ignition 2.3.7 requires php ^7.2.5 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 6
    - fzaninotto/faker is locked to version v1.9.1 and an update of this package was not requested.
    - fzaninotto/faker v1.9.1 requires php ^5.3.3 || ^7.0 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 7
    - nunomaduro/collision is locked to version v4.2.0 and an update of this package was not requested.
    - nunomaduro/collision v4.2.0 requires php ^7.2.5 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 8
    - phpunit/phpunit is locked to version 8.5.8 and an update of this package was not requested.
    - phpunit/phpunit 8.5.8 requires php ^7.2 -> your php version (8.0.0) does not satisfy that requirement.
  Problem 9
    - laravel/framework v7.28.0 requires php ^7.2.5 -> your php version (8.0.0) does not satisfy that requirement.
    - fruitcake/laravel-cors v2.0.2 requires illuminate/contracts ^6|^7|^8 -> satisfiable by laravel/framework[v7.28.0].
    - fruitcake/laravel-cors is locked to version v2.0.2 and an update of this package was not requested.


Installation failed, reverting ./composer.json and ./composer.lock to their original content.

Here I was trying to install unicodeveloper/laravel-paystack Please how do I solve this?

I also got his while trying to start another Laravel project of mine:

php artisan serve
PHP Fatal error:  Uncaught ErrorException: Method ReflectionParameter::getClass() is deprecated in /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php:838
Stack trace:
#0 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(838): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError()
#1 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(807): Illuminate\Container\Container->resolveDependencies()
#2 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(658): Illuminate\Container\Container->build()
#3 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(609): Illuminate\Container\Container->resolve()
#4 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(733): Illuminate\Container\Container->make()
#5 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(264): Illuminate\Foundation\Application->make()
#6 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(776): Illuminate\Container\Container->Illuminate\Container\{closure}()
#7 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(658): Illuminate\Container\Container->build()
#8 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(609): Illuminate\Container\Container->resolve()
#9 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(733): Illuminate\Container\Container->make()
#10 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(159): Illuminate\Foundation\Application->make()
#11 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(101): Illuminate\Foundation\Bootstrap\HandleExceptions->getExceptionHandler()
#12 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(87): Illuminate\Foundation\Bootstrap\HandleExceptions->renderForConsole()
#13 [internal function]: Illuminate\Foundation\Bootstrap\HandleExceptions->handleException()
#14 {main}
  thrown in /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 838
PHP Fatal error:  Uncaught ErrorException: Method ReflectionParameter::getClass() is deprecated in /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php:838
Stack trace:
#0 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(838): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError()
#1 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(807): Illuminate\Container\Container->resolveDependencies()
#2 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(658): Illuminate\Container\Container->build()
#3 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(609): Illuminate\Container\Container->resolve()
#4 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(733): Illuminate\Container\Container->make()
#5 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(264): Illuminate\Foundation\Application->make()
#6 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(776): Illuminate\Container\Container->Illuminate\Container\{closure}()
#7 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(658): Illuminate\Container\Container->build()
#8 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php(609): Illuminate\Container\Container->resolve()
#9 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Application.php(733): Illuminate\Container\Container->make()
#10 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(159): Illuminate\Foundation\Application->make()
#11 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(101): Illuminate\Foundation\Bootstrap\HandleExceptions->getExceptionHandler()
#12 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(87): Illuminate\Foundation\Bootstrap\HandleExceptions->renderForConsole()
#13 /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php(123): Illuminate\Foundation\Bootstrap\HandleExceptions->handleException()
#14 [internal function]: Illuminate\Foundation\Bootstrap\HandleExceptions->handleShutdown()
#15 {main}
  thrown in /home/cletus/Documents/techWorld/laravel/projects/Testing/Test again/decbee/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 838
Axel Köhler
  • 911
  • 1
  • 8
  • 34
  • https://blog.laravel.com/laravel-php-8-support -- There will be more libraries to update than the ones mentioned in the blog. You'll have to check each library to see how to make it compatible with PHP 8 – aynber Dec 31 '20 at 17:10
  • 1
    Your Laravel is said to be locked to `v7.28.0` which does not support PHP 8, maybe try running `composer update` to try to update Laravel to 7.30 which does support PHP 8 – apokryfos Dec 31 '20 at 17:37
  • Laravel 7 has been updated to support PHP 8, but you need to edit your composer.json to match the requirement versions in the current framework JSON (taking into account other packages you've required of course.) https://github.com/laravel/laravel/blob/7.x/composer.json – miken32 Dec 31 '20 at 18:14

0 Answers0