Skip to content

Conversation

DilumAluthge
Copy link
Member

@DilumAluthge DilumAluthge commented Oct 7, 2025

This is a follow-up to #35715.

Motivation

As I see it, my reasoning here is similar to our reasoning for requiring upper-bounded [compat] entries for packages registered in General. We don't let people register a package with a [compat] entry of the form MyDep = ">= 1.1.1", because there's no way for the package author to know or guarantee that MyDep v2 won't break their package.

Similarly, if a package author is using non-public Base functionality, then I don't think they should have a [compat] entry of the form julia = "1.12" (or julia = "^1.12"), because there's no way for the package author to know whether or not Julia 1.13 will break (or remove) the non-public functionality. It's thus safer for the package author to do julia = "~1.12", which will prevent users of Julia 1.13 from installing a broken version of the package.

A very risk-averse package author would do julia = "=1.12.0, =1.12.1, =1.12.2, ...", in case the functionality they rely on changes in a patch version. I don't think we need to recommend that level of strictness.

Arguments against tilde (or equals) [compat] specifiers

Breaks PkgEval

One argument against julia = "~1.12" is that it renders the package untestable in the PkgEval for the release-1.13 branch, because the Julia version on the release-1.13 branch is of the form 1.13.0-DEV..., which is incompatible with julia = "~1.12". So PkgEval wouldn't be able to test any packages with tilde (or equals) Julia [compat] entries. This is a problem, because the same package that uses non-Base public functionality is probably using some public Base functionality, and we want to run PkgEval to make sure we don't break the public Base functionality in that package.

I think we can work around this by having some special logic in PkgEval that rewrites tilde/equals compat entries to caret compat entries, thus allowing us to test these packages in PkgEval.

@DilumAluthge DilumAluthge added docs This change adds or pertains to documentation DO NOT MERGE Do not merge this PR! labels Oct 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DO NOT MERGE Do not merge this PR! docs This change adds or pertains to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant