openfoodfacts-laravel icon indicating copy to clipboard operation
openfoodfacts-laravel copied to clipboard

composer fail : laravel 9 compatibility

Open zakariayacine opened this issue 2 years ago • 1 comments

Hello, when i tried to install it in my project i had this error !

 Problem 1
    - openfoodfacts/openfoodfacts-laravel[dev-dependabot/github_actions/actions/cache-3.0.7, dev-explicit_geography, dev-master, v0.3.0] require openfoodfacts/openfoodfacts-php ^0.2.4 -> satisfiable by openfoodfacts/openfoodfacts-php[0.2.4].
    - openfoodfacts/openfoodfacts-laravel v0.1 requires illuminate/support 5.7.x|5.8.x|^6.0|^7.0 -> found illuminate/support[v5.7.0, ..., 5.8.x-dev, v6.0.0, ..., 6.x-dev, v7.0.0, ..., 7.x-dev] but these were not loaded, likely because it conflicts with another require.
    - openfoodfacts/openfoodfacts-laravel[v0.2, ..., v0.2.2] require illuminate/support 5.7.x|5.8.x|^6.0|^7.0|^8.0 -> found illuminate/support[v5.7.0, ..., 5.8.x-dev, v6.0.0, ..., 6.x-dev, v7.0.0, ..., 7.x-dev, v8.0.0, ..., 8.x-dev] but these were not loaded, likely because it conflicts with another require.
    - openfoodfacts/openfoodfacts-php 0.2.4 requires psr/log ^1.0 -> found psr/log[1.0.0, ..., 1.1.4] but the package is fixed to 3.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 openfoodfacts/openfoodfacts-laravel * -> satisfiable by openfoodfacts/openfoodfacts-laravel[dev-dependabot/github_actions/actions/cache-3.0.7, dev-explicit_geography, dev-master, v0.1, ..., v0.3.0, 9999999-dev].

Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.

Can anyone help me in this ! Im junior developper so im not very experimented thanks !!

zakariayacine avatar Aug 16 '22 20:08 zakariayacine

push

prey87 avatar Jan 11 '23 21:01 prey87

For Laravel 9, install:

  • using PHP 7.2-7.4: composer require "openfoodfacts/openfoodfacts-laravel:^0.2"
  • using PHP 8.0: composer require "openfoodfacts/openfoodfacts-laravel:^0.3"
  • using PHP 8.1: composer require openfoodfacts/openfoodfacts-laravel (regular install)
  • using PHP 8.2 or newer: upgrade to Laravel 10.x/11.x

epalmans avatar May 01 '24 10:05 epalmans