ERROR when try to install cretueusebiu/valet-windows - php

Hi Guys i try to install cretueusebiu/valet-windows, but i found the error like this :
$ composer global require cretueusebiu/valet-windows
Changed current directory to C:/Users/ROG/AppData/Roaming/Composer
Using version ^2.4 for cretueusebiu/valet-windows
./composer.json has been updated
Running composer update cretueusebiu/valet-windows
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- illuminate/container[v8.0.0, ..., v8.11.2] require php ^7.3 -> your php version (8.1.1) does not satisfy that requirement.
- illuminate/container[v8.12.0, ..., v8.77.1] require psr/container ^1.0 -> found psr/container[1.0.0, 1.1.0, 1.1.1, 1.1.2] but the package is fixed to 2.0.2 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
- cretueusebiu/valet-windows[2.4.0, ..., 2.4.1] require illuminate/container ^8.0 -> satisfiable by illuminate/container[v8.0.0, ..., v8.77.1].
- Root composer.json requires cretueusebiu/valet-windows ^2.4 -> satisfiable by cretueusebiu/valet-windows[2.4.0, 2.4.1].
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 cretueusebiu/valet-windows:*" to figure out if any version is installable, or "composer require cretueusebiu/valet-windows:^2.1" if you know which you need.
Installation failed, reverting ./composer.json and ./composer.lock to their original content.
can anyone help, Thanks

illuminate/container[v8.0.0, ..., v8.11.2] require php ^7.3 -> your (8.1.1)
The error is self-explanatory. The illuminate/container package requires PHP version 7.3 or above but not reaching 8.0 or above while you're PHP version is 8.1
If the package doesn't contain breaking changes for PHP 8 you can try installing using --ignore-platform-reqs flag like:
composer global require cretueusebiu/valet-windows --ignore-platform-reqs

Try to write this code to install...
composer global require cretueusebiu/valet-windows --with-all-dependencies

I solved it by downgrading my php version, thanks All

Related

Jetstream/Livewire package not installing

I installed a new laravel 8 project and tried to install Jetstream/Livewire but its giving me this error:
Your requirements could not be resolved to an installable set of packages.
Problem 1
- laravel/jetstream[v2.11.0, ..., 2.x-dev] require illuminate/console ^9.21 -> found illuminate/console[v9.21.0, ..., 9.x-dev] but these were not loaded, likely because it conflicts with another require.
- Root composer.json requires laravel/jetstream ^2.11 -> satisfiable by laravel/jetstream[v2.11.0, v2.11.1, v2.11.2, 2.x-dev].
You can also try re-running composer require with an explicit version constraint, e.g. "composer require laravel/jetstream:*" to figure out if any version is installable, or "composer require laravel/jetstream:^2.1" if you know which you need.
Installation failed, reverting ./composer.json and ./composer.lock to their original content.
I tried composer clear-cache and composer self-update and it still didn't work.
P.S I have to use laravel 8 because i'm on a tutorial that uses it.
I had to be specific with which version of jetstream/livewire I wanted to install and also had to allow all dependencies of the version to be installed, updated or downgraded.
This is the code I tried
composer require laravel/jetstream:^2.1 --with-all-dependencies
AND
php artisan jetstream:install livewire

Voyager Laravel installation problem (composer)

OS: Centos 8
PHP Version: Multi-php (7.2-default, 7.3, 7.4, 8.0)
Composer version 2.1.3
I have initialed a new laravel project:
/usr/bin/php74 /usr/local/bin/composer create-project --prefer-dist laravel/laravel:^7.0 test
(I'm using php 7.4 as a version)
After installing the default laravel project is working fine. Afterwards I want to add voyager. I'm entering the folder with cd and then running the command..
/usr/bin/php74 /usr/local/bin/composer require tcg/voyager
after running the command i'm getting errors:
Problem 1
- tcg/voyager[1.4.x-dev, ..., 1.x-dev] require intervention/image ^2.4 -> satisfiable by intervention/image[2.4.0, ..., 2.5.1].
- intervention/image 2.4.x-dev is an alias of intervention/image dev-master and thus requires it to be installed too.
- tcg/voyager[v1.4.0, ..., v1.4.2] require league/flysystem ~1.0.41 -> found league/flysystem[1.0.41, ..., 1.0.x-dev] but the
package is fixed to 1.1.4 (lock file version) by a partial update and
that version does not match. Make sure you list it as an argument for
the update command.
- intervention/image[dev-master, 2.4.0, ..., 2.5.1] require guzzlehttp/psr7 ~1.1 -> found guzzlehttp/psr7[1.1.0, ..., 1.x-dev] but
the package is fixed to 2.0.0 (lock file version) by a partial update
and that version does not match. Make sure you list it as an argument
for the update command.
- Root composer.json requires tcg/voyager ^1.4 -> satisfiable by tcg/voyager[v1.4.0, ..., 1.x-dev].
Use the option --with-all-dependencies (-W) to allow upgrades,
downgrades and removals for packages currently locked to specific
versions.
After running it with -W parameter:
Your requirements could not be resolved to an installable set of
packages.
Problem 1
- Root composer.json requires laravel/framework ^7.29, found laravel/framework[v7.29.0, ..., 7.x-dev] but these were not loaded,
likely because it conflicts with another require.
Installation failed, reverting ./composer.json and ./composer.lock to
their original content.
I have tried this with different variations (different php versions, last laravel version and more - same result - but these were not loaded, likely because it conflicts with another require.
I have read almost the whole internet with for this.., but nothing helped..
composer require tcg/voyager --with-all-dependencies
try the above command

laravel/ui[v3.0.0, ..., v3.2.0] require illuminate/console ^8.0 -> found illuminate/console[v8.0.0, ..., v8.36.2]

I am trying to make pdf using baaryvdh/dompdf in laravel but while installing the package using the command:
`composer require barryvdh/laravel-dompdf`
getting the error:
Using version ^0.9.0 for barryvdh/laravel-dompdf
./composer.json has been updated
Running composer update barryvdh/laravel-dompdf
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- laravel/ui[v3.0.0, ..., v3.2.0] require illuminate/console ^8.0 -> found illuminate/console[v8.0.0, ..., v8.36.2] but these were not loaded, likely because it conflicts with another require.
- Root composer.json requires laravel/ui ^3.0 -> satisfiable by laravel/ui[v3.0.0, v3.1.0, v3.2.0].
Run below command
composer require barryvdh/laravel-dompdf:0.8.5
But Remember above version needs,
This package requires php ^7.1.3.
Because if will not pass version bydefault it will take latest version and the latest version of dompdf is supported with laravel 8 and laravel ui 3.x
or
Please run "Composer update" Command
And Then Run
composer require barryvdh/laravel-dompdf:0.8.5
Hope this will work for you.

Laravel is not working with require laravel/ui

On executing composer require laravel/ui
I am getting below problems
Using version ^3.2 for laravel/ui
./composer.json has been updated
Running composer update laravel/ui
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 nesbot/carbon 2.0.0-beta.2 as 1.25.0, found nesbot/carbon[2.0.0-beta.2] but the package is fixed to 1.39.1 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
Problem 2
- Root composer.json requires kylekatarnls/laravel-carbon-2 ^1.0.0 -> satisfiable by kylekatarnls/laravel-carbon-2[1.0.0].
- kylekatarnls/laravel-carbon-2 1.0.0 requires nesbot/carbon ^2.0.0-beta.2 -> found nesbot/carbon[2.0.0-beta.2, ..., 2.46.0] but the package is fixed to 1.39.1 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
Problem 3
- Root composer.json requires laravel/ui ^3.2 -> satisfiable by laravel/ui[v3.2.0].
- laravel/ui v3.2.0 requires illuminate/console ^8.0 -> found illuminate/console[v8.0.0, ..., v8.33.1] but these were not loaded, likely because it conflicts with another require.
Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
Installation failed, reverting ./composer.json and ./composer.lock to their original content.
Composer File
You can try running composer update alone to update your dependencies. Let it update and then run composer require laravel/ui
Try to run "composer install" or "composer update" and after that run "composer require laravel/ui"
Try mentioning the ui version, may be you are using an older version of laravel
like
composer require laravel/ui:^2.4
Add the following dependencies to your composer.json**:
"nesbot/carbon": "2.0.0 as 1.25.0"
"kylekatarnls/laravel-carbon-2": "^1.0.0",
"laravel/ui": "^3.0",
Then run command
composer update
the issue resolved there is old version set on env variable on system that's why Laravel was installing on old version . I just add new env to system and start re installing the larval, I hope this will resolve my issue

Composer 2.0 Problems

Recently i attempted to install a package on a project i work on via Composer. Upon installing i was prompted a message that Composer 2.0 is released and asked me if i want to update it. Normally it seemed like a stable release but upon update the package wasnt installed and this error poped up.
composer require spatie/laravel-tags
Using version ^3.0 for spatie/laravel-tags
./composer.json has been updated
Running composer update spatie/laravel-tags
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 8.0, found laravel/framework[v8.0.0] but the package is fixed to v7.30.0 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
Problem 2
- spatie/laravel-tags[3.0.0, ..., 3.0.1] require laravel/framework ^8.0 -> found laravel/framework[v8.0.0, ..., 8.x-dev] but the package is fixed to v7.30.0 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
- Root composer.json requires spatie/laravel-tags ^3.0 -> satisfiable by spatie/laravel-tags[3.0.0, 3.0.1].
Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
Installation failed, reverting ./composer.json and ./composer.lock to their original content.
Anyone experienced this issue or have any guidelines how can i fix this?
Thanks
I have solved this by running composer outdated -D first and the manually update the versions of laravel/framework in composer.json and then ran composer update.

Categories