Skip to content
This repository has been archived by the owner on Jan 21, 2020. It is now read-only.

apigility version: 1.6.0 — zfcampus/statuslib-example installation fails #11

Open
fogelfish opened this issue May 15, 2018 · 4 comments

Comments

@fogelfish
Copy link

Following along with the official Apigility tutorial, I installed Apigility successfully:

composer create-project zfcampus/zf-apigility-skeleton ./apigility

Still following the instructions I got to this point:

composer require zfcampus/statuslib-example

but got this output:

Using version ^1.1 for zfcampus/statuslib-example
./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
    - Can only install one of: zendframework/zend-config[2.6.0, 3.2.0].
    - Can only install one of: zendframework/zend-config[3.2.0, 2.6.0].
    - Can only install one of: zendframework/zend-config[2.6.0, 3.2.0].
    - zfcampus/statuslib-example 1.1.0 requires zendframework/zend-config ^2.6 -> satisfiable by zendframework/zend-config[2.6.0].
    - Installation request for zfcampus/statuslib-example ^1.1 -> satisfiable by zfcampus/statuslib-example[1.1.0].
    - Installation request for zendframework/zend-config (locked at 3.2.0) -> satisfiable by zendframework/zend-config[3.2.0].

Installation failed, reverting ./composer.json to its original content.

The GitHub statuslib-example/composer.json file gives these requirements:

"require": {
    "php": "^5.6 || ^7.0",
    "ramsey/uuid": "^2.8",
    "zendframework/zend-config": "^2.6",
    "zendframework/zend-db": "^2.8.2",
    "zendframework/zend-paginator": "^2.7",
    "zendframework/zend-hydrator": "^1.1 || ^2.0",
    "zendframework/zend-stdlib": "^2.7.7 || ^3.0.1",
    "zfcampus/zf-configuration": "^1.0"
},

But in my installation of Apigility "zendframework/zend-config" is at 3.2.0. (Also "zendframework/zend-db" is at 2.9.3; "zendframework/zend-paginator" is at 2.8.1; "zfcampus/zf-configuration" is at 1.3.3; and I am using PHP 7.2.4.) Among these the only requirement that fails is zend-config" at 3.2.0.

How can I install zfcampus/statuslib-example?

@femiiisaa92
Copy link

Add this "zfcampus/statuslib-example": "^1.1" to the default Composer file in the project it look like this
"require": {
"php": "^5.6 || ^7.0",
"zendframework/zend-component-installer": "^1.1.1 || ^2.1.1",
"zfcampus/zf-apigility": "^1.4",
"zfcampus/zf-apigility-documentation": "^1.3",
"zfcampus/zf-development-mode": "^3.2",
"zfcampus/statuslib-example": "^1.1"
}
Then, composer update
It work for me.

@fredericboulanger
Copy link

Hi,

I have the same problem that fogelfish but for me your answer doesn't resolve my problem.

Using version ^1.1 for zfcampus/statuslib-example
./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
- Can only install one of: zendframework/zend-config[2.6.0, 3.2.0].
- Can only install one of: zendframework/zend-config[3.2.0, 2.6.0].
- zfcampus/statuslib-example 1.1.0 requires zendframework/zend-config ^2.6 -> satisfiable by zendframework/zend-config[2.6.0].
- Installation request for zfcampus/statuslib-example ^1.1 -> satisfiable by zfcampus/statuslib-example[1.1.0].
- Installation request for zendframework/zend-config (installed at 3.2.0) -> satisfiable by zendframework/zend-config[3.2.0].

Installation failed, reverting ./composer.json to its original content.

@krishnasrikanth
Copy link

Adding this line, as mentioned by femiiisaa92, worked for me.

"require": {
. . .
"zfcampus/statuslib-example": "^1.1"
. . .
}

After this, I had run "composer update", and it worked. FYI, I am running on PHP7.2.

@weierophinney
Copy link
Member

This repository has been closed and moved to laminas-api-tools/statuslib-example; a new issue has been opened at laminas-api-tools/statuslib-example#2.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants