New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pre-install setuptools-scm <6 in venv #5877
Conversation
Required in order to maintain support for Python 3.5, under Xenial. The python-dateutil package pulls in whatever the latest setuptools-scm version is, and as of setuptools_scm>=6, Python 3.5 is no longer supported.
Marking as WIP since ideally we'd pin an explicit hash for this build-time dependency. Submitting without hash-pinning to evaluate how CI likes it. |
Still no luck.
It is getting |
I am sad to read pypa/pip#3257, not implemented yet :( |
We have to install the correct version of setuptools_scm in the virtualenv created by the `dh-virtualenv` tool. This is managed by: https://github.com/spotify/dh-virtualenv/blob/0.11/dh_virtualenv/deployment.py#L145-L146 Only problem is that `pip` does not support hash verification when used via command line.
We have to install the correct version of https://github.com/spotify/dh-virtualenv/blob/0.11/dh_virtualenv/deployment.py#L145-L146 Only problem is that |
Builds locally for me - looks like v5.0.2 has to be specified in both places above. |
Very nice!
Is that so? Looks like my commit is maybe unnecessary, I'll try removing it and using only preinstall commit, and see if it still builds. |
Sorry no, my point was that both are required. It would be cool to have the dependency only specified in dh_virtualenv preinstall but it needs both. |
Great, thanks for clarifying. Confirmed locally that only the second commit isn't sufficient for a working build.
Yes, that's a bummer. Given that we're bumping up the end of the support window for Xenial, though, we may be stuck with this as an option for the final releases. |
Correct, because two different virtualenvs. |
Only good thing is that we are not going to support |
shell: > | ||
set -e && | ||
python3 -m venv /tmp/securedrop-app-code-i18n-ve && | ||
/tmp/securedrop-app-code-i18n-ve/bin/pip3 install "setuptools-scm==5.0.2" && |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note that hash checking is not performed on this dependency, but that was already the case, as it was being installed as a build dependency via python-dateutil's setup.py.
Hi. I just stumbled across this thread and thought I might be able to help. I have ended up with this:
Perhaps that's useful to you. An alternative could be:
All the best! EDIT: Went one step further to give you a drive-by PR: #5903 |
Status
Ready for review
Description of Changes
Fixes #5876
Required in order to maintain support for Python 3.5, under Xenial.
The python-dateutil package pulls in whatever the latest setuptools-scm
version is, and as of setuptools_scm>=6, Python 3.5 is no longer
supported.
Testing
CI must be passing.
Deployment
Unbreaks Xenial deb builds, so critical for deployment.