pip会忽略setup.py中的dependency_links [英] pip ignores dependency_links in setup.py

查看:80
本文介绍了pip会忽略setup.py中的dependency_links的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我的setup.py中有dependency_links:

I have dependency_links in my setup.py:

...
dependency_links = ['http://github.com/robot-republic/python-s3/tarball/master.tar.gz#egg=python-s3'],
...

但是它不起作用.但是install_requires可以正常工作. 也许还有另一种方法可以根据setup.py的要求设置git repo?

But it doesn't work. However install_requires works fine. Maybe there are another method to set up git repo as required for setup.py?

推荐答案

#egg=python-s3-1.0.0.

This answer should help. In a nutshell, you need to specify the version (or "dev") for the #egg=python-s3 so it looks like #egg=python-s3-1.0.0.

根据@Cerin的评论进行更新:

Updates based on @Cerin's comment:

  • Pip 1.5.x has a flag to enable dependency-links processing: --process-dependency-links. I haven't tested it because I agree with the point below.
  • This discussion seems to indicate that using dependency-links for pip is a bad practice. Although this feature was enlisted for deprecation, it's not anymore. There's a valid use case for private packages.

这篇关于pip会忽略setup.py中的dependency_links的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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