#Help with composer update
34 messages · Page 1 of 1 (latest)
is there a way i can upgrade this together?
So if you’re updating your Laravel framework version from 8.x to 9.x, you’re also going to need to update orchid/platform to a compatible version.
yes, but if i do that, i get the opposite error, that my laravel version does not match 
You need to update both at the same time
and if i try to do both it says the orchid is wrong version again
D:\Workspace\Web\riftq>composer update laravel/framework:v9 orchid/platform --with-all-dependencies
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Root composer.json requires laravel/framework ^v8.0, v9, found laravel/framework[dev-eloquent-collection-set-visible-hidden, dev-master, dev-revert-45453-where_key, dev-fix-predis-cluster, dev-feat/phpunit10, dev-process, v4.0
.0-BETA2, ..., 4.2.x-dev, v5.0.0, ..., 5.8.x-dev, v6.0.0, ..., 6.x-dev, v7.0.0, ..., 7.x-dev, v8.0.0, ..., 8.x-dev, v9.0.0-beta.1, ..., 9.x-dev, 10.x-dev, 11.x-dev (alias of dev-master)] but it does not match the constraint.
Problem 2
- Root composer.json requires orchid/platform 11.* -> satisfiable by orchid/platform[11.0.0, 11.0.1, 11.x-dev].
- orchid/platform[11.0.0, ..., 11.x-dev] require laravel/framework ^8.46 -> found laravel/framework[v8.46.0, ..., 8.x-dev] but it conflicts with your root composer.json require (^v8.0, v9).
Try removing it and then re-installing it so Composer tries and find a compatible version:
composer remove orchid/platform --no-scripts && composer require orchid/platform laravel/framework=^9.0
AAAAH
(╯°□°)╯︵ ┻━┻
now it cries bc of php version
Using version ^13.9 for orchid/platform
./composer.json has been updated
Running composer update orchid/platform laravel/framework
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Root composer.json requires laravel/framework 9.0 -> satisfiable by laravel/framework[v9.0.0].
- laravel/framework v9.0.0 requires php ^8.0.2 -> your php version (7.4.26) does not satisfy that requirement.
Problem 2
- Root composer.json requires orchid/platform ^13.9 -> satisfiable by orchid/platform[13.9.0, 13.9.1, 13.9.2, 13.9.3].
- orchid/platform[13.9.0, ..., 13.9.3] require laravel/framework ^9.21 -> found laravel/framework[v9.21.0, ..., 9.x-dev] but it conflicts with your root composer.json require (9.0).
Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
You can also try re-running composer require with an explicit version constraint, e.g. "composer require orchid/platform:*" to figure out if any version is installable, or "composer require orchid/platform:^2.1" if you know which yo
u need.
Installation failed, reverting ./composer.json and ./composer.lock to their original content.
this will be fun in production
i switch to php version 8 now
but how can i tell the project i did

D:\Workspace\Web\riftq>php --version
PHP 8.1.0 (cli) (built: Nov 23 2021 21:48:28) (ZTS Visual C++ 2019 x64)
Copyright (c) The PHP Group
Zend Engine v4.1.0, Copyright (c) Zend Technologies
your php version (7.4.26) does not satisfy that requirement.
You need to read these errors.
yes, i did. i also see that, i need to update it. hence the switch to php 8.1 as mentioned above. however it still wont allow me becasue php 7.4 is set in the composer.json as this:
"require": {
"php": "^7.4.0",
"ext-json": "*",
"doctrine/dbal": "2.*",
"fideloper/proxy": "^4.2",
...
Then change it.
You should just remove the line, since laravel/framework itself will declare a PHP version it needs to run.
Actually, no, sorry. Just change that line to "php": "^8.0.2"
It’s been a long day for me 😫
it's okay, im sorry to bother u like this anyway. but i tell u composer cross dependencies r not easy 
Yeah, you can get stuck in some pretty awkward inter-dependency hell like this.
If you change the PHP requirement to "php": "^8.0.2", then that should work with PHP 8.1 if that is the version you’re running on the command line.
okay, i changed that line
Your requirements could not be resolved to an installable set of packages.
Problem 1
- Root composer.json requires laravel/framework 9.0 -> satisfiable by laravel/framework[v9.0.0].
- laravel/framework v9.0.0 requires symfony/console ^6.0 -> found symfony/console[v6.0.0-BETA1, ..., 6.3.x-dev] but these were not loaded, likely because it conflicts with another require.
Problem 2
- Root composer.json requires orchid/platform ^13.9 -> satisfiable by orchid/platform[13.9.0, 13.9.1, 13.9.2, 13.9.3].
- orchid/platform[13.9.0, ..., 13.9.3] require laravel/framework ^9.21 -> found laravel/framework[v9.21.0, ..., 9.x-dev] but it conflicts with your root composer.json require (9.0).
Problem 3
- fzaninotto/faker is locked to version v1.9.2 and an update of this package was not requested.
- fzaninotto/faker v1.9.2 requires php ^5.3.3 || ^7.0 -> your php version (8.1.0) does not satisfy that requirement.
You can also try re-running composer require with an explicit version constraint, e.g. "composer require orchid/platform:*" to figure out if any version is installable, or "composer require orchid/platform:^2.1" if you know which yo
u need.
Now i get this. Let me read about symfony console n stuff in the upgrade guide, maybe they wrote something about having to add some packages there
i did now remove the fzaninotto/faker aswell..