Skip to content
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

Setuptools environment support logic incorrect #3266

Closed
jaraco opened this issue Feb 27, 2018 · 17 comments
Closed

Setuptools environment support logic incorrect #3266

jaraco opened this issue Feb 27, 2018 · 17 comments
Labels
status: needs information reporter needs to provide more information; can be closed after 2 or more weeks of inactivity type: infrastructure improvement to development/releases/CI structure
Milestone

Comments

@jaraco
Copy link
Contributor

jaraco commented Feb 27, 2018

I was looking at setup.py when I noticed ranged comparison in environment markers with older setuptools. It wasn't until setuptools 17.1 that environment markers supported ranged operators. So you may need a 1.5 level of support, or maybe you want to make 17.1 your minimum supported version for level 1 support.

@RonnyPfannschmidt
Copy link
Member

thanks for the note, we will try to resolve qickly

@RonnyPfannschmidt
Copy link
Member

@jaraco the comparison there is not ranged, its a plain < - my understanding is that those are supported

@nicoddemus nicoddemus added type: infrastructure improvement to development/releases/CI structure status: needs information reporter needs to provide more information; can be closed after 2 or more weeks of inactivity labels Feb 27, 2018
@jaraco
Copy link
Contributor Author

jaraco commented Mar 3, 2018

Hmm. < was what I meant by ranged operators. I believe Setuptools prior to 17.1 only supports version comparisons of equality and inequality.

@nicoddemus
Copy link
Member

Can we close this or is this still valid?

@RonnyPfannschmidt
Copy link
Member

i believe we should sort this out by using https://github.com/pytest-dev/pytest/blob/master/pyproject.toml#L3 and forcing a setuptools version that's supported

@nicoddemus
Copy link
Member

So it is just a matter of changing pyproject.toml to:

[build-system]
requires = [
  "setuptools>=17.1",
  "setuptools-scm",
  "wheel",
]

?

@RonnyPfannschmidt
Copy link
Member

@nicoddemus personally id like to go for a much more modern one and drop all the legacy creep in setup.py

@nicoddemus
Copy link
Member

@nicoddemus personally id like to go for a much more modern one and drop all the legacy creep in setup.py

I'm fine with that too. I think it is fair to require a reasonably recent version of setuptools and pip.

Which should be the minimum required version? This might be worth doing for the 3.9 release.

@RonnyPfannschmidt
Copy link
Member

we have more leeway to choose good for the 4.0 one

@nicoddemus
Copy link
Member

Hmm why is that? We have changed requirements of our dependencies in minor versions in the past.

@RonnyPfannschmidt
Copy link
Member

@nicoddemus setuptools in various older versions is used as part of more convoluted build processes at various types of enduser - i believe breaking them that way should be done in a more major release

@nicoddemus
Copy link
Member

OK thanks. I'm setting this to the 4.0 milestone then. 👍

@nicoddemus nicoddemus added this to the 4.0 milestone Oct 14, 2018
@jaraco
Copy link
Contributor Author

jaraco commented Oct 14, 2018

I’ve indicated setuptools >=30.3 in my projects’ pyproject.tomls with no ill effects. I recommend it and wouldn’t defer to a backward incompatible release.

@RonnyPfannschmidt
Copy link
Member

@jaraco thanks for that note, i'öö do t right now then

@RonnyPfannschmidt
Copy link
Member

@jaraco random other sidenote - is there anything in setuptools to have extensions for it obtain options from pyproject.toml - setup.cfg supports no extension at all (thus its a major pain for setuptools_scm)

@jaraco
Copy link
Contributor Author

jaraco commented Oct 15, 2018

is there anything in setuptools to have extensions for it obtain options from pyproject.toml

I doubt setuptools will ever get anything from pyproject.toml... at least not until it completely adopts distutils. As long as it depends on distutils, it will be bound to setup.cfg, so supporting another file just adds confusion. If I'm missing something, though, let's do DDD (documentation-driven development) and describe what you'd like to see from setuptools around using pyproject.toml to extend setuptools.

I do think it would be worthwhile to allow entry points to extend the declarative config, the same way that distutils_keywords can extend imperative config.

@RonnyPfannschmidt
Copy link
Member

@jaraco just trying to figure how to make extended setuptools_scm configuration less of a pain (that mapping is a pain to do correctly)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: needs information reporter needs to provide more information; can be closed after 2 or more weeks of inactivity type: infrastructure improvement to development/releases/CI structure
Projects
None yet
Development

No branches or pull requests

3 participants