-
Notifications
You must be signed in to change notification settings - Fork 212
Fix various bugs in match_version #565
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
Conversation
- Ignore yanked versions - Ignore pre-release versions - Add lots of tests Note: this now queries `releases.version` instead of `crates.versions` so that I have accessed to `releases.yanked`. This _shouldn't_ affect behavior, but if a previous bug set `crates.versions` to something different, it will no longer be seen. Closes rust-lang#223, rust-lang#221
Could someone else review this? |
Looks good to me but as not being familiar with this code, I think a third reviewer point of view would be appreciated. :) |
@koenaad would you be interested in reviewing this PR? |
@jyn514 yeah sure, I'll take a look at it later today. I don't feel super confident in my rust knowledge, but I should be able to review this 🙂 |
Awesome, thank you! It shouldn't be super complicated, feel free to ask here or on Discord if you have any questions. |
These changes look good to me, good work :) I don't have any comments on the code itself, just some general notes (not blocking for this PR):
|
Good call, done.
Hmm, I see the comment saying 'this should be part of match_version' but I'm not sure why - giving back the latest version with docs is very different from the latest version, that would be a big change in behavior. One of the things I was explicitly asked for #516 was to make sure it did not redirect to the latest successful version so people knew a later version was published. Returning the id sounds like a good refactor, but I think that should go in a different PR, I'll open an issue. |
Yeah, I agree it does not make much sense anymore given the current context... changing the implementation would break the usage of
Agree 👍 |
Note: this now queries
releases.version
instead ofcrates.versions
so that I have accessed to
releases.yanked
. This shouldn't affectbehavior, but if a previous bug set
crates.versions
to somethingdifferent, it will no longer be seen.
Closes #223, closes #221
r? @pietroalbini