Make `poetry remove <package>` work on dev-dependencies
See original GitHub issue- I have searched the issues of this repo and believe that this is not a duplicate.
- I have searched the documentation and believe that my question is not covered.
Feature Request
$ poetry add -D <package>
$ poetry remove <package>
ValueError
Package <package> not found
It’d be nice if remove
(and possibly other subcommands) would also look in the dev-dependencies
for convenience. The error message in this case seems rather confusing. Same works for example with yarn
.
Issue Analytics
- State:
- Created 3 years ago
- Reactions:2
- Comments:8 (4 by maintainers)
Top Results From Across the Web
Commands | Documentation | Poetry - Python dependency ...
This command will help you create a pyproject.toml file interactively by prompting you to provide basic information about your package. It will interactively ......
Read more >Poetry remove fails to remove any packages? - Stack Overflow
This worked for me. Although I did get the message The --dev option is deprecated, use the `--group dev` notation instead. – Bell....
Read more >Dependency Management With Python Poetry
A dependency manager like Python Poetry helps you specify, install, and resolve external packages in your projects. This way, you can be sure ......
Read more >Python packaging and dependency management using poetry
If you decide Poetry isn't your thing, you can completely remove it from your system by running the installer again with the --uninstall...
Read more >Managing Python Dependencies with Poetry
Now every time you run poetry install , development dependencies will also get installed. If don't want the packages listed under dev-dependencies section ......
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
There is already a feature request for this in https://github.com/python-poetry/poetry/issues/2058. That’s why I will close this one here.
I think the reason for confusion about the current behavior is, that only few people are aware, that one can define the same package in both section as @abn said.
IMO a confirm dialog would be fine. But also just removing the dep if it’s only in one section would be nice. (My personal opinion)
Thanks for finding that one and sorry for not searching throughly enough. GitHub search was not really helpful when searching for keywords like “remove” which are found in many issues.