Reputation: 21
I have some unnecessary packages in the [dev-packages]
section of my Pipfile and I cannot uninstall them with the latest Pipenv (2024.0.1). Uninstalling packages from the [packages]
section of the Pipfile works fine.
I've tried all of pipenv uninstall packagename
, pipenv uninstall --dev packagename
, and pipenv uninstall -d packagename
all to the same non-effect.
Here is the output when trying to uninstall python-docx
:
% pipenv uninstall --dev python-docx
Building requirements...
Resolving dependencies...
✔ Success!
Uninstalling python-docx...
pipenv uninstall --dev python-docx 8.97s user 1.07s system 84% cpu 11.921 total
Nothing changes in the Pipfile. The Pipfile.lock has some extraneous changes but still contains the python-docx
package.
% git diff Pipfile.lock
diff --git a/Pipfile.lock b/Pipfile.lock
index 5b761ce..b3ad052 100644
--- a/Pipfile.lock
+++ b/Pipfile.lock
@@ -296,14 +296,6 @@
"markers": "python_version >= '3.5'",
"version": "==3.6"
},
- "importlib-metadata": {
- "hashes": [
- "sha256:4805911c3a4ec7c3966410053e9ec6a1fecd629117df5adee56dfc9432a1081e",
- "sha256:f238736bb06590ae52ac1fab06a3a9ef1d8dce2b7a35b5ab329371d6c8f5d2cc"
- ],
- "markers": "python_version < '3.10'",
- "version": "==7.0.1"
- },
"jinja2": {
"hashes": [
"sha256:7d6d50dd97d52cbc355597bd845fabfbac3f551e1f99619e39a35ce8c370b5fa",
@@ -657,14 +649,6 @@
"markers": "python_version >= '2.7' and python_version not in '3.0, 3.1, 3.2, 3.3, 3.4, 3.5'",
"version": "==1.26.18"
},
- "zipp": {
- "hashes": [
- "sha256:0e923e726174922dce09c53c59ad483ff7bbb8e572e00c7f7c46b88556409f31",
- "sha256:84e64a1c28cf7e91ed2078bb8cc8c259cb19b76942096c8d7b84947690cabaf0"
- ],
- "markers": "python_version >= '3.8'",
- "version": "==3.17.0"
- },
"zope.event": {
"hashes": [
"sha256:2832e95014f4db26c47a13fdaef84cef2f4df37e66b59d8f1f4a8f319a632c26",
(END)
Upvotes: 2
Views: 159
Reputation: 21
It seems that you have to run pipenv uninstall --all-dev
to remove all dev packages first, and then reinstall those you need.
Upvotes: 1