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
User not warned/informed about version normalization #3745
Comments
Hi @buhtz, I will reclassify this issue as a FR because my understanding is that setuptools is working as intended (it follows the specs) and you would like to propose a change in behaviour to be implemented. In principle, I am (personally) against using a warning because it has the potential of breaking many CI setups (it is a common/recommended practice to set Something that could be done is to print an informative message for the user. If you or any other member of the community is interested in this direction, I think the best way forward would be submitting a PR. |
I'm against re-classifying this Issue as a FR. If you see a FR please open a new one and link them.
I don't see how a message on "stderr" would break "many CI setups". It is a bug because setuptools does silently modifies what the user specifies.
This is OK for me and I assume there are good reason why setuptools does not allow hyphens at that position. But the wish of the users need to be respected in a way to inform him that his wished specs are not able to fulfill by the tool he choose. |
Hi @buhtz,
I agree that a message on stderr will not break any CI. This is exactly what I am agreeing in the phrase Another completely different different thing is to use Python warnings system. If using Python warnings system, any CI setup that (correctly) uses Right now I am trying to do some issue triaging. So I would like you to kindly cooperate in the classification of the issue. But please feel free to submit a PR implementing the change requested. |
OK, there was a misunderstanding. I interpreted your "print" as I'm not familiar with the warning system of Python. |
Yeah, |
Additional information: But in [PEP440])[https://peps.python.org/pep-0440/#semantic-versioning) it was mentioned as a workaround to replace the |
Hi @buhtz, PEP 440 says that
PEP 440 suggests using
The PEP also says:
|
setuptools version
latest
Python version
3.9.2
OS
GNU/Linux Debian
Additional environment information
No response
Description
I was redirected from this pip issue into here. Not sure if I'm correct here. There is also an Issue about the topic in the SemVer repo.
In my
pyproject.toml
I specified the version that way.Please note that there is a
-
between major.minor.patch (0.0.0
) and the pre-release (a7
).But when installing that package the
-
is ignored and the version converted into0.0.0a7
.You can see in the output of
pip
that the version number used is different from the number I specified in mypyproject.toml
.Please note that this breaks Semantiv Versioning. The hyphen is mandatory. I'm aware of thhe paragraph in PEP440 mentioning this exception.
Expected behavior
I'm sure there are reason why you do it that way.
But you have to inform the users when modifying a specification he made in its
pyproject.toml
. This should throw a warning when you take the version string and modify it.How to Reproduce
s.o.
Output
s.o.
The text was updated successfully, but these errors were encountered: