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

Allow non-semver (and epocs) #3844

Open
PallHaraldsson opened this issue Mar 13, 2024 · 2 comments
Open

Allow non-semver (and epocs) #3844

PallHaraldsson opened this issue Mar 13, 2024 · 2 comments

Comments

@PallHaraldsson
Copy link

PallHaraldsson commented Mar 13, 2024

Version numbers use semver, and do not allow epocs.

I'm thinking, if a package user does not want to follow semver, does Pkg presume it? I'm not actually sure what happens if you disregard semver, in packages (not proposing for Julia itself...).

It's possible that some users will want it, and it seemingly should be its private decision. But then we have a conflict if changing later to semver (seemingly ok to change from semver to calender based though, only a problem in other direction), why epocs:

https://peps.python.org/pep-0440/#version-epochs

We don't have to adopt Python's version spec in full, but maybe some parts, at least epocs might be useful, and implied 0, i.e. 0! prefix if none...

@KristofferC KristofferC transferred this issue from JuliaLang/julia Mar 13, 2024
@PallHaraldsson
Copy link
Author

PallHaraldsson commented Mar 13, 2024

[I maybe should have posted here at Pkg, though version parsing is in Base... the question on it - and Pkg.]

Extra question, in short, this is intended (and documented?) or a bug (I was editing, adding this, and lost my longer edit while issue moved to Pkg...)?

julia> v"∞"
v"∞"

julia> @edit tryparse(VersionNumber, "∞")

@mkitti
Copy link
Contributor

mkitti commented Mar 14, 2024

I'm not completely following. Could we just map epoch to the major version number?

E!X.Y just becomes E.X.Y

This seems to be the domain of VersionParsing.jl:

https://github.com/JuliaInterop/VersionParsing.jl

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants