I'm using Laravel 5.8 although 6.0.3 is available. I'm using it because the tutorial I'm following is using Laravel 5.8.
When, I command:
composer require laravel/passport
it throws an error
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Conclusion: remove laravel/framework v5.8.35
- Conclusion: don't install laravel/framework v5.8.35
- laravel/passport 8.x-dev requires illuminate/encryption ^6.0|^7.0 -> satisfiable by illuminate/encryption[6.x-dev, 7.0.x-dev, v6.0.0, v6.0.1, v6.0.2, v6.0.3, v6.0.4, v6.1.0, v6.2.0, v6.3.0, v6.4.1].
- laravel/passport v8.0.0 requires illuminate/encryption ^6.0|^7.0 -> satisfiable by illuminate/encryption[6.x-dev, 7.0.x-dev, v6.0.0, v6.0.1, v6.0.2, v6.0.3, v6.0.4, v6.1.0, v6.2.0, v6.3.0, v6.4.1].
- don't install illuminate/encryption 6.x-dev|don't install laravel/framework v5.8.35
- don't install illuminate/encryption 7.0.x-dev|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.0.0|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.0.1|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.0.2|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.0.3|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.0.4|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.1.0|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.2.0|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.3.0|don't install laravel/framework v5.8.35
- don't install illuminate/encryption v6.4.1|don't install laravel/framework v5.8.35
- Installation request for laravel/framework (locked at v5.8.35, required as 5.8.*) -> satisfiable by laravel/framework[v5.8.35].
- Installation request for laravel/passport ^8.0 -> satisfiable by laravel/passport[8.x-dev, v8.0.0].
Installation failed, reverting ./composer.json to its original content.
Latest version of Laravel Passport dropped support for Laravel 5.8
Install earlier version
composer require laravel/passport:7.5.1
From the release notes of Laravel Passport
Changed
Rework HandlesOAuthErrors trait to middleware (#937)
Use a renderable exception for OAuth errors (#1066)
Use diactoros 2.0 and psr-http-factory (aadf603)
Replaced helpers with Blade directives (#939)
Use caret for constraints (d906804)
Dropped support for Laravel 5.8 (654cc09)
Dropped support for PHP 7.1 (3c830ac)
Upgrade to league/oauth2-server 8.0 (97e3026)
You can use this command to install passport on laravel 5.8 projects: composer require laravel/passport "7.5.1" or you can include passport in composer dependecies:
"require": {
...
"laravel/passport": "7.5.1",
....
}
and then run composer update Both will install passport in your project.
composer require laravel/passport works on the latest version of laravel.
You have to download the version according to your laravel version.
So to solve, go-to Laravel docs and select the version you are currently running and then go to Passport it will show you the appropriate version of Passport to install for your version of laravel.
Related
I am working on bagiato(laravel). When I run the command "composer require laravel/ui" this error comes.
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Conclusion: don't install illuminate/console v7.12.0
- don't install illuminate/console 7.x-dev|don't install laravel/framework v6.18.15
- don't install illuminate/console 7.x-dev|remove laravel/framework v6.18.15
- don't install illuminate/console 7.x-dev|don't install laravel/framework v6.18.15
- Installation request for illuminate/console ^7.12 -> satisfiable by illuminate/console[7.x-dev, v7.12.0].
- Installation request for laravel/framework (locked at v6.18.15, required as ^6.0) -> satisfiable by laravel/framework[v6.18.15].
You are trying to install the wrong version of laravel/ui.
laravel/ui version 1 is what you want. Version 2 is trying to install and only laravel 7+ supports it.
composer require vendor/package:version
composer require laravel/ui:1.2.0 <- latest version of laravel/ui that works with Laravel 6
As a part of Laravel 5.7 setup, I am trying to install Passport using the command:
composer require laravel/passport
But it doesn't work and gives the error:
Using version ^8.0 for laravel/passport
./composer.json has been updated
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Conclusion: remove laravel/framework v5.7.15
- Conclusion: don't install laravel/framework v5.7.15
- laravel/passport 8.x-dev requires illuminate/support ^6.0|^7.0 -> satisfiable by laravel/framework[6.x-dev], illuminate/support[6.x-dev, 7.0.x-dev, v6.0.0, v6.0.1, v6.0.2, v6.0.3, v6.0.4, v6.1.0, v6.2.0, v6.3.0, v6.4.1, v6.5.0, v6.5.1, v6.5.2, v6.6.0].
- laravel/passport v8.0.0 requires illuminate/support ^6.0|^7.0 -> satisfiable by laravel/framework[6.x-dev], illuminate/support[6.x-dev, 7.0.x-dev, v6.0.0, v6.0.1, v6.0.2, v6.0.3, v6.0.4, v6.1.0, v6.2.0, v6.3.0, v6.4.1, v6.5.0, v6.5.1, v6.5.2, v6.6.0].
- laravel/passport v8.0.1 requires illuminate/support ^6.0|^7.0 -> satisfiable by laravel/framework[6.x-dev], illuminate/support[6.x-dev, 7.0.x-dev, v6.0.0, v6.0.1, v6.0.2, v6.0.3, v6.0.4, v6.1.0, v6.2.0, v6.3.0, v6.4.1, v6.5.0, v6.5.1, v6.5.2, v6.6.0].
- laravel/passport v8.0.2 requires illuminate/support ^6.0|^7.0 -> satisfiable by laravel/framework[6.x-dev], illuminate/support[6.x-dev, 7.0.x-dev, v6.0.0, v6.0.1, v6.0.2, v6.0.3, v6.0.4, v6.1.0, v6.2.0, v6.3.0, v6.4.1, v6.5.0, v6.5.1, v6.5.2, v6.6.0].
- Can only install one of: laravel/framework[6.x-dev, v5.7.15].
- don't install illuminate/support 6.x-dev|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.0.0|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.0.1|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.0.2|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.0.3|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.0.4|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.1.0|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.2.0|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.3.0|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.4.1|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.5.0|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.5.1|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.5.2|don't install laravel/framework v5.7.15
- don't install illuminate/support v6.6.0|don't install laravel/framework v5.7.15
- don't install illuminate/support 7.0.x-dev|don't install laravel/framework v5.7.15
- Installation request for laravel/framework (locked at v5.7.15, required as 5.7.*) -> satisfiable by laravel/framework[v5.7.15].
- Installation request for laravel/passport ^8.0 -> satisfiable by laravel/passport[8.x-dev, v8.0.0, v8.0.1, v8.0.2].
Installation failed, reverting ./composer.json to its original content.
It looks like the Passport version 8.0 is not compatible with the Version 5.7.15 of Laravel, which version is compatible here?
I have simply chosen the older version of Passport: v7.5.1
composer require laravel/passport "7.5.1"
and the installation worked successfully:
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 15 installs, 0 updates, 0 removals
- Installing psr/http-message (1.0.1): Loading from cache
- Installing psr/http-factory (1.0.1): Loading from cache
- Installing zendframework/zend-diactoros (2.2.1): Loading from cache
- Installing symfony/psr-http-message-bridge (v1.3.0): Loading from cache
- Installing phpseclib/phpseclib (2.0.23): Loading from cache
- Installing defuse/php-encryption (v2.2.1): Loading from cache
- Installing lcobucci/jwt (3.3.1): Loading from cache
- Installing league/event (2.2.0): Loading from cache
- Installing league/oauth2-server (7.4.0): Downloading (100%)
- Installing ralouphie/getallheaders (3.0.3): Loading from cache
- Installing guzzlehttp/psr7 (1.6.1): Loading from cache
- Installing guzzlehttp/promises (v1.3.1): Loading from cache
- Installing guzzlehttp/guzzle (6.4.1): Loading from cache
- Installing firebase/php-jwt (v5.0.0): Loading from cache
- Installing laravel/passport (v7.5.1): Downloading (100%)
symfony/psr-http-message-bridge suggests installing nyholm/psr7 (For a super lightweight PSR-7/17 implementation)
phpseclib/phpseclib suggests installing ext-libsodium (SSH2/SFTP can make use of some algorithms provided by the libsodium-php extension.)
phpseclib/phpseclib suggests installing ext-mcrypt (Install the Mcrypt extension in order to speed up a few other cryptographic operations.)
phpseclib/phpseclib suggests installing ext-gmp (Install the GMP (GNU Multiple Precision) extension in order to speed up arbitrary precision integer arithmetic operations.)
guzzlehttp/psr7 suggests installing zendframework/zend-httphandlerrunner (Emit PSR-7 responses)
Writing lock file
Generating optimized autoload files
Carbon 1 is deprecated, see how to migrate to Carbon 2.
https://carbon.nesbot.com/docs/#api-carbon-2
You can run './vendor/bin/upgrade-carbon' to get help in updating carbon and other frameworks and libraries that depend on it.
> Illuminate\Foundation\ComposerScripts::postAutoloadDump
> #php artisan package:discover --ansi
Discovered Package: beyondcode/laravel-dump-server
Discovered Package: fideloper/proxy
Discovered Package: laravel/passport
Discovered Package: laravel/tinker
Discovered Package: nesbot/carbon
Discovered Package: nunomaduro/collision
Package manifest generated successfully.
Passport 10.* requires Laravel 8.*.
https://github.com/laravel/passport/blob/master/UPGRADE.md
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Installation request for realrashid/sweet-alert ^2.0 -> satisfiable by realrashid/sweet-alert[v2.0].
- Conclusion: remove laravel/framework v6.0.0
- Conclusion: don't install laravel/framework v6.0.0
- realrashid/sweet-alert v2.0 requires laravel/framework ~5.4.0|~5.8.0|~5.9.0 -> satisfiable by laravel/framework[5.4.x-dev, 5.8.x-dev].
- Can only install one of: laravel/framework[5.8.x-dev, v6.0.0].
- Can only install one of: laravel/framework[5.4.x-dev, v6.0.0].
- Installation request for laravel/framework (locked at v6.0.0, required as ^6.0) -> satisfiable by laravel/framework[v6.0.0].
The realrashid/sweet-alert package has not been updated for use in Laravel 6.0. You will have to wait until it is updated, update the package yourself, or use a different package for SweetAlert2.
Update: The package has been updated for use with Laravel 6.0.
composer require realrashid/sweet-alert
I'm working on a project and i'm trying to upgrade my current version of php 5.6 to 7.3, laravel 5.3 to 5.8 and backpack 0.7 to final version, then ran composer update but all I got was the error below:
Problem 1:
- Conclusion: don't install laravel/framework v5.8.19
- Conclusion: don't install laravel/framework v5.8.18
- Conclusion: don't install laravel/framework v5.8.17
- Conclusion: don't install laravel/framework v5.8.16
- Conclusion: don't install laravel/framework v5.8.15
- Conclusion: don't install laravel/framework v5.8.14
- Conclusion: don't install laravel/framework v5.8.13
- Conclusion: don't install laravel/framework v5.8.12
- Conclusion: don't install laravel/framework v5.8.11
- Conclusion: don't install laravel/framework v5.8.10
- Conclusion: don't install laravel/framework v5.8.9
- Conclusion: don't install laravel/framework v5.8.8
- Conclusion: don't install laravel/framework v5.8.7
- Conclusion: don't install laravel/framework v5.8.6
- Conclusion: don't install laravel/framework v5.8.5
- Conclusion: don't install laravel/framework v5.8.4
- Conclusion: don't install laravel/framework v5.8.3
- Conclusion: don't install laravel/framework v5.8.2
- Conclusion: don't install laravel/framework v5.8.1
- laravelcollective/html v5.3.1 requires illuminate/view 5.3.* -> satisfiable by laravel/framework[v5.3.31], illuminate/view[v5.3.0, v5.3.16, v5.3.23, v5.3.4].
- laravelcollective/html v5.3.1 requires illuminate/view 5.3.* -> satisfiable by laravel/framework[v5.3.31], illuminate/view[v5.3.0, v5.3.16, v5.3.23, v5.3.4].
- Can only install one of: laravel/framework[v5.8.0, v5.3.31].
- don't install illuminate/view v5.3.0|don't install laravel/framework v5.8.0
- don't install illuminate/view v5.3.16|don't install laravel/framework v5.8.0
- don't install illuminate/view v5.3.23|don't install laravel/framework v5.8.0
- don't install illuminate/view v5.3.4|don't install laravel/framework v5.8.0
- Installation request for laravel/framework 5.8.* -> satisfiable by laravel/framework[v5.8.0, v5.8.1, v5.8.10, v5.8.11, v5.8.12, v5.8.13, v5.8.14, v5.8.15, v5.8.16, v5.8.17, v5.8.18, v5.8.19, v5.8.2, v5.8.3, v5.8.4, v5.8.5, v5.8.6, v5.8.7, v5.8.8, v5.8.9].
- Installation request for laravelcollective/html 5.3.1 -> satisfiable by laravelcollective/html[v5.3.1].
This is composer.json requirement
"require": {
"php": ">=7.3.1",
"laravel/framework": "5.3.*",
"laravelcollective/html": "5.3.1",
"backpack/base": "^0.7.14",
"backpack/crud": "^3.1",
"backpack/permissionmanager": "^2.1",
"backpack/langfilemanager": "^1.0",
"mikehaertl/phpwkhtmltopdf": "2.2.1",
"artisaninweb/laravel-soap": "0.3.0.7",
When upgrading Laravel and/or Backpack, it's recommended that you don't jump versions. I've never tried to jump from L5.3 directly to 5.8, but I do not expect that to work.
Both Laravel and Backpack release upgrade guides with each version. That's because the upgrade process is not just changing a number in the composer.json file. It also involves some steps you need to do manually. Otherwise your app won't work. I know it's inconvenient, but it's the only possible way to upgrade code that you can customize.
My recommendation:
Upgrade to Laravel 5.4 & Backpack 3.2
Then upgrade to Laravel 5.5 & Backpack 3.3
Then upgrade to Laravel 5.6 & Backpack 3.4
Then upgrade to Laravel 5.7 & Backpack 3.5
Then upgrade to Laravel 5.8 & Backpack 3.6
You can automate a good part of the Laravel upgrades using Laravel Shift. It's a paid service that makes pull requests to your Github/Gitlab/Bitbucket repo. You can't automate the Backpack upgrades, I'm afraid, but in most cases the steps will be clear and the changes small.
Hope it helps.
I'm trying to update Laravel 5.3 to Laravel 5.4 that was released yesturday, and I get this message:
Problem 1
- laravelcollective/html 5.3.x-dev requires illuminate/view 5.3.* -> satisfiable by laravel/framework[v5.3.20], illuminate/view[v5.3.0, v5.3.16, v5.3.23, v5.3.4].
- laravelcollective/html 5.3.x-dev requires illuminate/view 5.3.* -> satisfiable by laravel/framework[v5.3.20], illuminate/view[v5.3.0, v5.3.16, v5.3.23, v5.3.4].
- laravelcollective/html 5.3.x-dev requires illuminate/view 5.3.* -> satisfiable by laravel/framework[v5.3.20], illuminate/view[v5.3.0, v5.3.16, v5.3.23, v5.3.4].
- Can only install one of: laravel/framework[v5.4.0, v5.3.20].
- don't install illuminate/view v5.3.0|don't install laravel/framework v5.4.0
- don't install illuminate/view v5.3.16|don't install laravel/framework v5.4.0
- don't install illuminate/view v5.3.23|don't install laravel/framework v5.4.0
- don't install illuminate/view v5.3.4|don't install laravel/framework v5.4.0
- Installation request for laravel/framework 5.4.0 -> satisfiable by laravel/framework[v5.4.0].
- Installation request for laravelcollective/html 5.3.*-dev -> satisfiable by laravelcollective/html[5.3.x-dev].
Thing is I don't see laravelcollective has release a 5.4 version.
Do I need to wait for them to release new version or am I missing something?
Why isn't it in the upgrade guide, it is a quite important lib in Laravel.
You have some options. Laravel Collective is a popular package, so people are already applying the fixes required for it to work on 5.4. Check out the following thread on a pull request.
https://github.com/LaravelCollective/html/pull/276
So, in order to use the package with 5.4, based on comments in the thread, you'll need to change your composer.json to look like this.
"laravel/collective": "5.4.x-dev",
Then run composer update
If you want you can also use a specific commit. In this case, to use the commit on this pull request, your composer.json would look like so.
"laravelcollective/html": "dev-master#92f3ba71c5c11c752ddd68d614f5f0665e759220",