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
Fix Compatibility Check for Prereleases #7723
Conversation
Thanks for making a pull request to JupyterLab! To try out this branch on binder, follow this link: |
That's too bad. So this comment isn't true anymore? |
The comment is still true. The extension author can just specify the new final version or any prerelease version and it will work. |
# to not have to update their versions for each | ||
# Jupyterlab prerelease version. | ||
if x1.prerelease: | ||
x1 = x1.inc('patch') |
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.
Can we make this behavior an option in the function? As a standalone function, it's surprising that it ignores the prerelease option on just one end of one of the ranges. Would we get the same end result if we had an "increment prerelease" flag as an argument, and then just did this logic on both ends of both ranges?
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.
Sure, we can make this behavior optional in the standalone function. It only has an effect on the lower end of the range, since ~2.0.0-b1
gets interpreted originally as 2.0.0-b1 <= x < 2.1.0
and converted to 2.0.0 <= x < 2.1.0
. By doing it on the lower end of the first argument, we are saying that we don't do compatibility checks within our own prerelease cycle only.
Thanks! |
References
Fixes #7241
The previous behavior is as follows:
^1.x
is seen overlapping with~2.0.0-x.y
because2.0.0-x.y
is less than2.0.0
in our logic^1.x
is not seen as overlapping with~2.0.0
(verified locally)This changes the logic to always strip our prelease info when doing the version compatibility check.
With these changes, the latest
@jupyter-widgets/jupyterlab-manager
cannot be installed into the alpha release:However, an extension that declares a dependency on any prerelease version or final version of JupyterLab can be installed (tested with a local extension depending on
"@jupyterlab/application": "^2.0.0-rc.0"
and"@jupyterlab/application": "^2.0.0"
).Code changes
Compare against final releases in the version compatibility check.
User-facing changes
Users can no longer install incompatible extensions during the prerelease cycle.
Backwards-incompatible changes
Incompatible extensions can no longer be installed.