setuptools_scm: pip install -r requirements.txt fails to "setuptools-scm was unable to detect version for '/tmp'"
Version: 1.15.0
I have requirements declared in setup.py
, so with requirements.txt
file of:
.
pip install -r requirement.txt
:
Processing /home/musttu/Code/lib/wires/aws
Complete output from command python setup.py egg_info:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-pgsLbN-build/setup.py", line 31, in <module>
'pastry-common==3.2.1.dev30',
File "/usr/lib/python2.7/distutils/core.py", line 111, in setup
_setup_distribution = dist = klass(attrs)
File "/home/musttu/Code/virtualenvs/wires/local/lib/python2.7/site-packages/setuptools/dist.py", line 318, in __init__
_Distribution.__init__(self, attrs)
File "/usr/lib/python2.7/distutils/dist.py", line 287, in __init__
self.finalize_options()
File "/home/musttu/Code/virtualenvs/wires/local/lib/python2.7/site-packages/setuptools/dist.py", line 376, in finalize_options
ep.load()(self, ep.name, value)
File "/home/musttu/Code/virtualenvs/wires/local/lib/python2.7/site-packages/setuptools_scm/integration.py", line 19, in version_keyword
dist.metadata.version = get_version(**value)
File "/home/musttu/Code/virtualenvs/wires/local/lib/python2.7/site-packages/setuptools_scm/__init__.py", line 117, in get_version
parsed_version = _do_parse(root, parse)
File "/home/musttu/Code/virtualenvs/wires/local/lib/python2.7/site-packages/setuptools_scm/__init__.py", line 95, in _do_parse
"use git+https://github.com/user/proj.git#egg=proj" % root)
LookupError: setuptools-scm was unable to detect version for '/tmp'.
I don’t believe it’s possible to fix this within setuptools-scm
, however. If pip uses /tmp
for temporarily building/handling the package, there’s simply no version information available and nothing to be done. Correct? Would you have any guesses if it’s possible to make it work on pip side?
There is a related ticket in https://github.com/pypa/setuptools_scm/issues/46 but I think that was closed because user tried to install an sdist there.
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 31 (16 by maintainers)
Commits related to this issue
- fix #138 - add support for the pip-egg-info folder — committed to RonnyPfannschmidt/setuptools_scm by RonnyPfannschmidt 7 years ago
- fix #138 - add support for the pip-egg-info folder — committed to RonnyPfannschmidt/setuptools_scm by RonnyPfannschmidt 7 years ago
- Merge pull request #148 from RonnyPfannschmidt/fix-138/pip-egg-info-fallback fix #138 - add support for the pip-egg-info folder — committed to pypa/setuptools_scm by RonnyPfannschmidt 7 years ago
i believe we may figure more from verbose output + setting
SETUPTOOLS_SCM_DEBUG=1
in the environment