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
Avoid installation failure with newer setuptools #591
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,3 +35,4 @@ pip-log.txt | |
# Coverage artifacts | ||
.coverage | ||
coverage.xml | ||
pip-wheel-metadata |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
[build-system] | ||
requires = [ | ||
"setuptools == 41.0.0", # See https://github.com/pypa/setuptools/issues/1869 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. plz don't pin old setuptools. Patch There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This does not pin setuptools inside the venv, is only the version used for building from source. It would not affect the setuptools version on the system. See:
As you can see above, the virtualenv still has the latest setuptools, the one that caused the breakage. Build config is only about how-to-build the wheel, not how to install it. Re proposal to fix setup.py,.... @webknjaz you are welcomed to fix it yourself, I did not write that code and I looked at it and failed to identify a way to fix it, especially quickly. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. thanks zbr for working on that we need this + the fix at #590 (or does that one also fix this sorin?) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can we make a pragmatic decision and merge this and debate later about what older versions we need to cover for? We can delay a release based on these concerns but not a merge that is fixing broken CI. We can later identify which are those cases and add tests for them. As of today, Ansible documentation does not mention any minimal or maximal version of pip, on the opposite it does mention that you may need to upgrade pip. This implies that latest version of pip should work. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is reasonable. You'll be able to use commit SHA in your pre-commit config. |
||
"setuptools_scm >= 1.15.0", | ||
"setuptools_scm_git_archive >= 1.0", | ||
"wheel", | ||
] | ||
build-backend = "setuptools.build_meta" |
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.
btw, by adding this you effectively break editable mode.
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.
I defer, I tested both
pip install .
andpip install -e .
and they both worked fine (py37/macos). Did you tried them and failed? If so, which environment?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.
The problem is that PEP517 has no notion of "editable install" atm.
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.
Also, which version of Pip?
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.
pip==19.3
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.
@webknjaz Also check #592 which is supposed to fix the setup.py -- I do not care which one goes in as long we fix ansible-lint itself. It is a huge pain to introduce workarounds everywhere is used.
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.
Both break things, hence not ready for merge.
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.
That sentence is a bit blurry and clearly not actionable. What use-case is broken? What needs to be done to bring it to ready-to-merge status?
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.
PEP517 ignores the existence of editable installs making Pip behavior unpredictable. I know of at least one Pip version that errors out under such circumstances.
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.
The action here is to wait for the decision whether we can drop support for older envs.