I am creating my own slackbot. I decided to use project as a library to help me.
https://github.com/sagebind/slack-client/issues?utf8=%E2%9C%93&q=stability
Now I need to install it with composer.
So I used the command: composer require coderstephen/slack-client
...And I get the error:
Problem 1 - Installation request for coderstephen/slack-client ^0.3.0 -> satisfiable by coderstephen/slack-client[v0.3.0]. - coderstephen/slack-client v0.3.0 requires devristo/phpws dev-master -> satisfiable by devristo/phpws[dev-master] but these conflict with your requirements or minimum-stability.
Ok - So then I decided to change my stability level to "dev" in my composer.lock
:
"aliases": [], "minimum-stability": "dev", "stability-flags": { "devristo/phpws": 20 }, "prefer-stable": true, "prefer-lowest": false, "platform": { "php": ">=5.5" }, "platform-dev": []
Now I'm running out of ideas on what to do. The README says to do this step in composer.json but, no such settings exist:
Please note that the current version has unstable dependencies.
In order to install those dependencies, you can set "minimum-stability" in your composer.json, and recommend that you set "prefer-stable":
My composer.json:
{ "name": "coderstephen/slack-client", "keywords": ["slack", "api", "realtime"], "license": "MIT", "description": "A better Slack client, with RTM API support", "authors": [{ "name": "Stephen Coakley", "email": "[email protected]" }], "require": { "php": ">=5.5", "devristo/phpws": "dev-master", "evenement/evenement": "2.0.*", "guzzlehttp/guzzle": "~6.0", "react/event-loop": "^0.4.1", "react/promise": "^2.2" }, "require-dev": { "phpunit/phpunit": "~4.6", "fzaninotto/faker": "~1.4", "apigen/apigen": "^4.1" }, "autoload": { "psr-4": { "Slack\\": "src" } }, "autoload-dev": { "psr-4": { "Slack\\Tests\\": "tests" } } }
Does anyone know some solutions I could try?
Add minimum-stability
and prefer-stable
to your composer.json
(not composer.lock
):
{ "name": "coderstephen/slack-client", "keywords": ["slack", "api", "realtime"], "license": "MIT", "description": "A better Slack client, with RTM API support", "authors": [{ "name": "Stephen Coakley", "email": "[email protected]" }], "require": { "php": ">=5.5", "devristo/phpws": "dev-master", "evenement/evenement": "2.0.*", "guzzlehttp/guzzle": "~6.0", "react/event-loop": "^0.4.1", "react/promise": "^2.2" }, "require-dev": { "phpunit/phpunit": "~4.6", "fzaninotto/faker": "~1.4", "apigen/apigen": "^4.1" }, "autoload": { "psr-4": { "Slack\\": "src" } }, "autoload-dev": { "psr-4": { "Slack\\Tests\\": "tests" } }, "minimum-stability": "dev", "prefer-stable": true }
For others having the same issue, these changes are best done using composer itself instead of manually modifying the composer.json file. Just run the following commands in the console:
$ composer config minimum-stability dev
$ composer config prefer-stable true
Now you can require and update the package:
$ composer require --no-update "vendor/package-name:version"
$ composer update
Available options (in order of stability) are dev, alpha, beta, RC, and stable
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With