升级软件包而无需使用pip升级依赖项? [英] Upgrade package without upgrading dependencies using pip?

查看:81
本文介绍了升级软件包而无需使用pip升级依赖项?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在为我的python应用程序使用pip和virtualenv.我想升级到该应用程序的新版本,而又无需碰到任何依赖关系.当我使用pip install -U时,它将尝试升级所有软件包,甚至在没有可用的新版本时,甚至卸载并重新安装相同版本的依赖项软件包.

I'm using pip and virtualenv for my python application. I would like to upgrade to a new version of the application without touching the dependencies. When I use pip install -U, it tries to upgrade all the packages, and even uninstalls and re-installs the same version of a dependency package when there isn't a new version available.

我也尝试过pip install -U --no-deps,但这似乎等同于常规安装而不是升级.是否有组合的标志可以满足我的需求?

I also tried pip install -U --no-deps but that seems equivalent to a regular install instead of an upgrade. Is there a combination of flags that will do what I want?

推荐答案

我刚刚尝试了我的virtualenv项目,并且pip install -U --no-deps mypackage似乎工作正常.它只是下载mypackage而没有其他内容.您的设置是什么样的?

I just tried on my virtualenv project and pip install -U --no-deps mypackage seems to work just fine. It just download mypackage and nothing else. What's your set up like?

这篇关于升级软件包而无需使用pip升级依赖项?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆