-
Notifications
You must be signed in to change notification settings - Fork 3.1k
Closed
Labels
C: vcspip's interaction with version control systems like git, svn and bzrpip's interaction with version control systems like git, svn and bzrauto-lockedOutdated issues that have been locked by automationOutdated issues that have been locked by automationstate: needs reproducerNeed to reproduce issueNeed to reproduce issue
Description
- Pip version:
19.2.3
,19.2.3
- Python version:
2.7
,3.5.5
- Operating System:
Ubuntu 14.04
,Ubuntu 18.04
Description:
When using setuptools-scm
in a git sub-directory, version detection mechanism fails.
With GIT_REPO/subdir/requirements.txt
:
.
With GIT_REPO/subdir/setup.py
:
from setuptools import setup, find_packages
from setuptools_scm import get_version
setup(
name='pastry-auth',
version=get_version(root='..', relative_to=__file__),
)
Executing pip install -r requirements.txt
in GIT_REPO/subdir
, pip copies GIT_REPO/subdir
to /tmp/pip-<hash>-build/
and so when setuptools-scm
attempts to determine the version of parent directory (root='..'
declaration), it then looks up /tmp
, which doesn't have the repository information, and fails.
I faced this in pypa/setuptools-scm#138. It prevents setuptools_scm
from detecting git version when you hold multiple components in one git repository (in sub-directories), when having .
in requirements.txt
.
Metadata
Metadata
Assignees
Labels
C: vcspip's interaction with version control systems like git, svn and bzrpip's interaction with version control systems like git, svn and bzrauto-lockedOutdated issues that have been locked by automationOutdated issues that have been locked by automationstate: needs reproducerNeed to reproduce issueNeed to reproduce issue