pulkitjalan/google-apiclient

Cannot install version 3.0

tyteen4a03 opened this issue · 7 comments

I'm getting this error when trying to install the package via Composer:

  Problem 1
    - Conclusion: don't install phpseclib/phpseclib 2.0.2
    - Installation request for tymon/jwt-auth 0.5.* -> satisfiable by tymon/jwt-auth[0.5.0, 0.5.1, 0.5.2, 0.5.3, 0.5.4, 0.5.5, 0.5.6, 0.5.7, 0.5.8, 0.5.9].
    - Installation request for pulkitjalan/google-apiclient 3.* -> satisfiable by pulkitjalan/google-apiclient[3.0.0].
    - Conclusion: don't install phpseclib/phpseclib 2.0.1
    - pulkitjalan/google-apiclient 3.0.0 requires google/apiclient ^2.0 -> satisfiable by google/apiclient[v2.0.0, v2.0.1].
    - google/apiclient v2.0.0 requires phpseclib/phpseclib ~2.0 -> satisfiable by phpseclib/phpseclib[2.0.0, 2.0.1, 2.0.2].
    - google/apiclient v2.0.1 requires phpseclib/phpseclib ~2.0 -> satisfiable by phpseclib/phpseclib[2.0.0, 2.0.1, 2.0.2].
    - Conclusion: don't install phpseclib/phpseclib 2.0.0|install phpseclib/phpseclib 2.0.1|install phpseclib/phpseclib 2.0.2

My composer.json looks like this:

    "require": {
        "php": ">=5.5.9",
        "laravel/framework": "5.2.*",
        "filp/whoops": "~1.0",
        "tymon/jwt-auth": "0.5.*",
        "pulkitjalan/google-apiclient": "3.*"
    },
    "require-dev": {
        "fzaninotto/faker": "~1.4",
        "mockery/mockery": "0.9.*",
        "phpunit/phpunit": "~4.0",
        "phpspec/phpspec": "~2.1",
        "laracasts/generators": "^1.1",
        "symfony/dom-crawler": "~3.0",
        "symfony/css-selector": "~3.0"
    },

Not sure what's wrong here since I was able to install the package with the last version.

it looks like its because google/apiclient v2 requires phpseclib/phpseclib ~2.0, a different package must require a different version and thats causing a conflict.

google/apiclient v1 didn't require it, so there was nothing to conflict...

I'm getting another one when I deleted /vendor and started again:

  Problem 1
    - Installation request for pulkitjalan/google-apiclient ^3.0 -> satisfiable by pulkitjalan/google-apiclient[3.0.0].
    - Conclusion: remove phpseclib/phpseclib 0.3.10
    - Conclusion: don't install phpseclib/phpseclib 0.3.10
    - pulkitjalan/google-apiclient 3.0.0 requires google/apiclient ^2.0 -> satisfiable by google/apiclient[v2.0.0, v2.0.1].
    - google/apiclient v2.0.0 requires phpseclib/phpseclib ~2.0 -> satisfiable by phpseclib/phpseclib[2.0.0, 2.0.1, 2.0.2].
    - google/apiclient v2.0.1 requires phpseclib/phpseclib ~2.0 -> satisfiable by phpseclib/phpseclib[2.0.0, 2.0.1, 2.0.2].
    - Can only install one of: phpseclib/phpseclib[2.0.0, 0.3.10].
    - Can only install one of: phpseclib/phpseclib[2.0.1, 0.3.10].
    - Can only install one of: phpseclib/phpseclib[2.0.2, 0.3.10].
    - Installation request for phpseclib/phpseclib (locked at 0.3.10) -> satisfiable by phpseclib/phpseclib[0.3.10].

I see now; seems to be an issue with JWTAuth.

As it says in the output there:

Can only install one of: phpseclib/phpseclib[2.0.0, 0.3.10].

google/apiclient v2 requires phpseclib/phpseclib ~2.0, so composer will need to install phpseclib/phpseclib version 2, however it looks like another one of your required packages (or package dependencies) requires phpseclib/phpseclib 0.3.10.

Composer can install 2 different versions of the same package...

ok cool

So what is the solution for this issue ?