Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
weierophinney opened this issue Dec 31, 2019 · 3 comments

Comments

@weierophinney
Copy link
Contributor

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?


Originally posted by @fogelfish at zfcampus/statuslib-example#11

@weierophinney
Copy link
Contributor Author

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.


Originally posted by @femiiisaa92 at zfcampus/statuslib-example#11 (comment)

@weierophinney
Copy link
Contributor Author

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.


Originally posted by @fredericboulanger at zfcampus/statuslib-example#11 (comment)

@weierophinney
Copy link
Contributor Author

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.


Originally posted by @krishnasrikanth at zfcampus/statuslib-example#11 (comment)

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

No branches or pull requests

1 participant