{"action":"created","issue":{"url":"https://api.github.com/repos/composer/composer/issues/5652","repository_url":"https://api.github.com/repos/composer/composer","labels_url":"https://api.github.com/repos/composer/composer/issues/5652/labels{/name}","comments_url":"https://api.github.com/repos/composer/composer/issues/5652/comments","events_url":"https://api.github.com/repos/composer/composer/issues/5652/events","html_url":"https://github.com/composer/composer/issues/5652","id":175393587,"number":5652,"title":"--no-dev does not ignore require-dev","user":{"login":"bp1222","id":516652,"avatar_url":"https://avatars.githubusercontent.com/u/516652?v=3","gravatar_id":"","url":"https://api.github.com/users/bp1222","html_url":"https://github.com/bp1222","followers_url":"https://api.github.com/users/bp1222/followers","following_url":"https://api.github.com/users/bp1222/following{/other_user}","gists_url":"https://api.github.com/users/bp1222/gists{/gist_id}","starred_url":"https://api.github.com/users/bp1222/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bp1222/subscriptions","organizations_url":"https://api.github.com/users/bp1222/orgs","repos_url":"https://api.github.com/users/bp1222/repos","events_url":"https://api.github.com/users/bp1222/events{/privacy}","received_events_url":"https://api.github.com/users/bp1222/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":17,"created_at":"2016-09-07T01:46:20Z","updated_at":"2016-09-08T15:01:31Z","closed_at":"2016-09-07T06:44:53Z","body":"I have provided two repositories that show this issue happening.\r\n\r\n[Application](https://github.com/bp1222/application) is an example application that requires `~1.0.0` of the [Library](https://github.com/bp1222/library).  The library has 3 deployed tags, `1.0.0`, `1.0.1`, and `dev-master`.  The repository for library is located via Satis @ [packages.mudsite.com](https://packages.mudsite.com)\r\n\r\nThe Applications composer.json consists of:\r\n```json\r\n{\r\n    \"name\": \"bp1222/application\",\r\n    \"description\": \"Example Application\",\r\n    \"type\": \"project\",\r\n    \"repositories\": [\r\n        {\r\n            \"type\": \"composer\",\r\n            \"url\": \"https://packages.mudsite.com\"\r\n        }\r\n    ],\r\n    \"require\": {\r\n        \"php\": \">=5.6.0\",\r\n        \"bp1222/library\": \"~1.0.0\"\r\n    },\r\n    \"require-dev\": {\r\n        \"bp1222/library\": \"dev-master as 1.0.0\"\r\n    }\r\n}\r\n```\r\n\r\nThe Libraries composer.json consists of:\r\n```json\r\n{\r\n    \"name\": \"bp1222/library\",\r\n    \"description\": \"Example Library\",\r\n    \"type\": \"library\",\r\n    \"minimum-stability\": \"dev\",\r\n    \"require\": {\r\n        \"php\": \">=5.6.0\"\r\n    }\r\n}\r\n```\r\n\r\n**Running With \"require-dev\" containing the \"dev-master as 1.0.0\" line**\r\nWhen I run this command from the Applications:\r\n```\r\ndwalker@linux:~/composertest/application › composer.phar update --no-dev\r\n```\r\n\r\nI get this output:\r\n```\r\nLoading composer repositories with package information\r\nUpdating dependencies\r\n  - Installing bp1222/library (dev-master 436c7d0)\r\n    Cloning 436c7d0e8db859627b337fb83ab1af0c7f6e8459 from cache\r\n\r\nWriting lock file\r\nGenerating autoload files\r\n```\r\n\r\nAnd I expected this to happen:\r\nI expect Library `1.0.1` to be installed, not `dev-master` at a commit past `1.0.1`\r\n\r\n**Running With Applications \"require-dev\" empty**\r\nWhen I run this command from the Applications:\r\n```\r\ndwalker@linux:~/composertest/application › composer.phar update --no-dev\r\n```\r\n\r\nI get this output:\r\n```\r\nLoading composer repositories with package information\r\nUpdating dependencies\r\n  - Installing bp1222/library (1.0.1)\r\n    Downloading: 100%         \r\n\r\nGenerating autoload files\r\n```\r\n\r\nAnd I expected this to happen:\r\nI expect this to happen, this is the correct behavior."},"comment":{"url":"https://api.github.com/repos/composer/composer/issues/comments/245627072","html_url":"https://github.com/composer/composer/issues/5652#issuecomment-245627072","issue_url":"https://api.github.com/repos/composer/composer/issues/5652","id":245627072,"user":{"login":"Seldaek","id":183678,"avatar_url":"https://avatars.githubusercontent.com/u/183678?v=3","gravatar_id":"","url":"https://api.github.com/users/Seldaek","html_url":"https://github.com/Seldaek","followers_url":"https://api.github.com/users/Seldaek/followers","following_url":"https://api.github.com/users/Seldaek/following{/other_user}","gists_url":"https://api.github.com/users/Seldaek/gists{/gist_id}","starred_url":"https://api.github.com/users/Seldaek/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Seldaek/subscriptions","organizations_url":"https://api.github.com/users/Seldaek/orgs","repos_url":"https://api.github.com/users/Seldaek/repos","events_url":"https://api.github.com/users/Seldaek/events{/privacy}","received_events_url":"https://api.github.com/users/Seldaek/received_events","type":"User","site_admin":false},"created_at":"2016-09-08T15:01:31Z","updated_at":"2016-09-08T15:01:31Z","body":"You can install the lib as a clone even without requiring dev-master btw, see https://getcomposer.org/doc/06-config.md#preferred-install - then you can go in there and checkout master if you need to patch something. "}}
{"actor":{"display_login":"Seldaek"}}