Laravel Error Message : Your requirements could not be resolved to an installable set of packages.

Posted on

Another article written to discuss how to interpret a message generated as shown in the title which is ‘Your requirements could not be resolved to an installable set of packages.’. In this context, the message shown when a command below is executed in the bash prompt :

composer require "laravelcollective/html":"5.1.*"

Below is the output generated by the above command execution in the bash prompt located in the root folder of a Laravel-based web application and in this context or article, it is located in /var/www/html/testing/laravel-project :

 
user@hostname:/var/www/html/testing/laravel-project$ composer require "laravelcollective/html":"5.1.*"
./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.3.31
    - Conclusion: don't install laravel/framework v5.3.31
    - laravelcollective/html v5.1.0 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.1 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.2 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.3 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.4 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.5 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.6 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.7 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.8 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - laravelcollective/html v5.1.9 requires illuminate/routing 5.1.* -> satisfiable by illuminate/routing[v5.1.1, v5.1.13, v5.1.16, v5.1.2, v5.1.20, v5.1.22, v5.1.25, v5.1.28, v5.1.30, v5.1.31, v5.1.41, v5.1.6, v5.1.8].
    - don't install illuminate/routing v5.1.1|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.13|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.16|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.2|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.20|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.22|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.25|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.28|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.30|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.31|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.41|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.6|don't install laravel/framework v5.3.31
    - don't install illuminate/routing v5.1.8|don't install laravel/framework v5.3.31
    - Installation request for laravel/framework (locked at v5.3.31, required as 5.3.*) -> satisfiable by laravel/framework[v5.3.31].
    - Installation request for laravelcollective/html 5.1.* -> satisfiable by laravelcollective/html[v5.1.0, v5.1.1, v5.1.2, v5.1.3, v5.1.4, v5.1.5, v5.1.6, v5.1.7, v5.1.8, v5.1.9].
Installation failed, reverting ./composer.json to its original content.
user@hostname:/var/www/html/testing/laravel-project$ 

There is a problem on processing the installation of package laravelcollective/html for the 5.1.* version as shown in the above output generated :

Your requirements could not be resolved to an installable set of packages.

It is precisely announced in the end of the output command as follows :

- Installation request for laravelcollective/html 5.1.* -> satisfiable by laravelcollective/html[v5.1.0, v5.1.1, v5.1.2, v5.1.3, v5.1.4, v5.1.5, v5.1.6, v5.1.7, v5.1.8, v5.1.9].

Since the already installed laravel framework version is 5.3.* it is not compatible for the additional installation package of laravelcollective/html 5.1.* because is only satisfiable for the version shown above.

The solution for the above problem is by changing the version of the laravelcollective/html which is going to be installed where it must be satisfiable or compatible with the already installed laravelframework version 5.3.*. So, just re-execute the above command as follows :

user@hostname:/var/www/html/testing/laravel-project$ composer require "laravelcollective/html":"5.3.*"
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 1 install, 0 updates, 0 removals
  - Installing laravelcollective/html (v5.3.1): Downloading (100%)         
Package illuminate/html is abandoned, you should avoid using it. Use laravelcollective/html instead.
Writing lock file
Generating autoload files
> Illuminate\Foundation\ComposerScripts::postUpdate
> php artisan optimize
Generating optimized class loader
The compiled class file has been removed.
user@hostname:/var/www/html/testing/laravel-project$ 

One thought on “Laravel Error Message : Your requirements could not be resolved to an installable set of packages.

Leave a Reply