-
Notifications
You must be signed in to change notification settings - Fork 645
#468 encourage stable version #577
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
#468 encourage stable version #577
Conversation
— Elliot Jackson <[email protected]>
— Elliot Jackson <[email protected]>
Good PR. |
Any thoughts on adding realease candidates marked |
I think rc should be added, yeah. But "prealpha" getting weeded out by the "alpha" flag check makes me nervous about adding "rc"-- since we're not matching on the entire label, what if someone made a label that said "arc" or "anarchy" or some other word that contained "rc"? The version would be hidden, but I don't think that's what would be expected... I think this feature would be more understandable if we either have a fixed list of exact, fully matched words that will get a version to be not recommended on the crate's page, or if we say that any string after the version number will cause it to not be recommended, unless there aren't any versions without a string. Steve's comment here says "Especially given that you don't get a pre-release version without specifically selecting it; this seems quite consistent." I'm going to go check out cargo's code and see if it matches on particular strings or if it's any string, the behavior here should match whatever behavior is in the version resolver code. Do you remember what the problems were when you tried to update the fixtures? I can take a look at that too. |
Ok yeah i think this is defined in the semver spec's precedence rules, which the semver crate (and thus cargo) follow:
A version is considered a prerelease version if there is any value in the prerelease spot, not any particular values like "alpha" or "rc", etc. So I think we should hide any version that has any value for prerelease, unless all versions of the crate have values for prerelease. |
Thanks for digging into this. Crates should definitely match Cargo's implementation! I'll get this PR updated as time permits — probably towards the start of next week.
These were the changes I made. I don't remember what the errors were exactly, but I got them when running Ember's test suite. |
Take your time! I'll try out the fixtures, although ember and i have done our fair share of disagreeing on what is and should be happening in the tests :P |
Oh i see! The test that fails for me when I use your fixture changes says So when you get a chance to make the change that any prerelease string should count as a non-stable version, could you rebase to remove the commit where you took the fixture changes back out, then update the test message as well? Thank you!! ❤️ |
`includes` is valid ES6 but Phantom doesn't seem to like it: the tests fail with it set. Reverted to the tried and true `indexOf`. All tests are passing. — Elliot Jackson <[email protected]>
4861503
to
32d7218
Compare
@carols10cents I undid the commit that reverted my fixture changes and updated the test to expect 13 instead of 12 as you suggested above — everything's passing now 👍
|
Works great!! Thank you!! |
…-ember-7.7.2, r=Turbo87 Bump eslint-plugin-ember from 7.0.0 to 7.7.2 Bumps [eslint-plugin-ember](https://github.com/ember-cli/eslint-plugin-ember) from 7.0.0 to 7.7.2. <details> <summary>Release notes</summary> *Sourced from [eslint-plugin-ember's releases](https://github.com/ember-cli/eslint-plugin-ember/releases).* > ## v7.7.2 > #### 🐛 Bug Fix > * [#621](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/621) Fix false positive with `ignoreNonThisExpressions` option in `use-ember-get-and-set` rule ([@​Exelord](https://github.com/Exelord)) > > #### 📝 Documentation > * [#620](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/620) Use consistent prefixes for rule descriptions ([@​bmish](https://github.com/bmish)) > > #### 🏠 Internal > * [#625](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/625) Add eslint-plugin-jest internally and enable rules ([@​bmish](https://github.com/bmish)) > * [#624](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/624) Add eslint-plugin-unicorn internally and enable recommended rules ([@​bmish](https://github.com/bmish)) > > #### Committers: 2 > - Bryan Mishkin ([@​bmish](https://github.com/bmish)) > - Maciej Kwaśniak ([@​Exelord](https://github.com/Exelord)) > > ## v7.7.1 > #### 🐛 Bug Fix > * [#615](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/615) Fix issue causing assert to fire in `getSourceModuleName` util function ([@​patocallaghan](https://github.com/patocallaghan)) > > #### Committers: 1 > - Pat O'Callaghan ([@​patocallaghan](https://github.com/patocallaghan)) > > ## v7.7.0 > #### 🚀 Enhancement > * [#592](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/592) Update `no-classic-classes` rule to catch classic Ember Data model classes ([@​patocallaghan](https://github.com/patocallaghan)) > > #### 🐛 Bug Fix > * [#610](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/610) Fix invalid `no-get` rule autofix caused by invalid JS variable name ([@​bmish](https://github.com/bmish)) > * [#607](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/607) Fix spread property bug in `require-super-in-init` rule ([@​bmish](https://github.com/bmish)) > * [#600](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/600) Add missing schema validation for options on many rules ([@​bmish](https://github.com/bmish)) > > #### 🏠 Internal > * [#611](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/611) Add many missing tests for lines without test coverage ([@​bmish](https://github.com/bmish)) > > #### Committers: 2 > - Bryan Mishkin ([@​bmish](https://github.com/bmish)) > - Pat O'Callaghan ([@​patocallaghan](https://github.com/patocallaghan)) > > ## v7.6.0 > #### 🚀 Enhancement > * [#594](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/594) Add new rule `no-get-with-default` ([@​steventsao](https://github.com/steventsao)) > > #### Committers: 1 > - Steven Tsao ([@​steventsao](https://github.com/steventsao)) > > ## v7.5.0 > #### 🚀 Enhancement > * [#583](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/583) Update `no-observers` rule to handle decorators ([@​bmish](https://github.com/bmish)) > * [#577](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/577) Add autofixer to `no-get` rule ([@​bmish](https://github.com/bmish)) > ></tr></table> ... (truncated) </details> <details> <summary>Changelog</summary> *Sourced from [eslint-plugin-ember's changelog](https://github.com/ember-cli/eslint-plugin-ember/blob/master/CHANGELOG.md).* > ## v7.7.2 (2019-12-12) > > #### 🐛 Bug Fix > * [#621](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/621) Fix false positive with `ignoreNonThisExpressions` option in `use-ember-get-and-set` rule ([@​Exelord](https://github.com/Exelord)) > > #### 📝 Documentation > * [#620](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/620) Use consistent prefixes for rule descriptions ([@​bmish](https://github.com/bmish)) > > #### 🏠 Internal > * [#625](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/625) Add eslint-plugin-jest internally and enable rules ([@​bmish](https://github.com/bmish)) > * [#624](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/624) Add eslint-plugin-unicorn internally and enable recommended rules ([@​bmish](https://github.com/bmish)) > > #### Committers: 2 > - Bryan Mishkin ([@​bmish](https://github.com/bmish)) > - Maciej Kwaśniak ([@​Exelord](https://github.com/Exelord)) > > ## v7.7.1 (2019-11-29) > > #### 🐛 Bug Fix > * [#615](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/615) Fix issue causing assert to fire in `getSourceModuleName` util function ([@​patocallaghan](https://github.com/patocallaghan)) > > #### Committers: 1 > - Pat O'Callaghan ([@​patocallaghan](https://github.com/patocallaghan)) > > ## v7.7.0 (2019-11-29) > > #### 🚀 Enhancement > * [#592](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/592) Update `no-classic-classes` rule to catch classic Ember Data model classes ([@​patocallaghan](https://github.com/patocallaghan)) > > #### 🐛 Bug Fix > * [#610](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/610) Fix invalid `no-get` rule autofix caused by invalid JS variable name ([@​bmish](https://github.com/bmish)) > * [#607](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/607) Fix spread property bug in `require-super-in-init` rule ([@​bmish](https://github.com/bmish)) > * [#600](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/600) Add missing schema validation for options on many rules ([@​bmish](https://github.com/bmish)) > > #### 🏠 Internal > * [#611](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/611) Add many missing tests for lines without test coverage ([@​bmish](https://github.com/bmish)) > > #### Committers: 2 > - Bryan Mishkin ([@​bmish](https://github.com/bmish)) > - Pat O'Callaghan ([@​patocallaghan](https://github.com/patocallaghan)) > > ## v7.6.0 (2019-11-19) > > #### 🚀 Enhancement > * [#594](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/pull/594) Add new rule `no-get-with-default` ([@​steventsao](https://github.com/steventsao)) > > #### Committers: 1 > - Steven Tsao ([@​steventsao](https://github.com/steventsao)) > > ## v7.5.0 (2019-11-11) ></tr></table> ... (truncated) </details> <details> <summary>Commits</summary> - [`1805883`](ember-cli/eslint-plugin-ember@1805883) v7.7.2 - [`39539bc`](ember-cli/eslint-plugin-ember@39539bc) Update CHANGELOG - [`9943b7e`](ember-cli/eslint-plugin-ember@9943b7e) Merge pull request [#625](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/issues/625) from bmish/eslint-plugin-jest - [`cb4824d`](ember-cli/eslint-plugin-ember@cb4824d) chore(lint): add eslint-plugin-jest internally and enable rules - [`dc149b5`](ember-cli/eslint-plugin-ember@dc149b5) Merge pull request [#624](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/issues/624) from bmish/eslint-plugin-unicorn - [`9a6a4be`](ember-cli/eslint-plugin-ember@9a6a4be) chore(lint): add eslint-plugin-unicorn internally and autofix recommended rules - [`c93198c`](ember-cli/eslint-plugin-ember@c93198c) build(deps-dev): bump eslint-plugin-import from 2.18.2 to 2.19.1 ([#623](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/issues/623)) - [`e2c5235`](ember-cli/eslint-plugin-ember@e2c5235) build(deps): bump snake-case from 3.0.1 to 3.0.2 ([#622](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/issues/622)) - [`4c6aedd`](ember-cli/eslint-plugin-ember@4c6aedd) Merge pull request [#621](https://github-redirect.dependabot.com/ember-cli/eslint-plugin-ember/issues/621) from Exelord/fix/ignore-this-expressions - [`ed6301a`](ember-cli/eslint-plugin-ember@ed6301a) chore: fix lint violation - Additional commits viewable in [compare view](ember-cli/eslint-plugin-ember@v7.0.0...v7.7.2) </details> <br /> [](https://dependabot.com/compatibility-score.html?dependency-name=eslint-plugin-ember&package-manager=npm_and_yarn&previous-version=7.0.0&new-version=7.7.2) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- **Note:** This repo was added to Dependabot recently, so you'll receive a maximum of 5 PRs for your first few update runs. Once an update run creates fewer than 5 PRs we'll remove that limit. You can always request more updates by clicking `Bump now` in your [Dependabot dashboard](https://app.dependabot.com). <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) - `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language - `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language - `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language - `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language - `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com): - Update frequency (including time of day and day of week) - Pull request limits (per update run and/or open at any time) - Automerge options (never/patch/minor, and dev/runtime dependencies) - Out-of-range updates (receive only lockfile updates, if desired) - Security updates (receive only security updates, if desired) </details>
The changes in this PR update a crate’s index page to show the latest stable release, which is defined as the last version uploaded that doesn’t include the strings “alpha” or “beta” as per #468.
I updated the fixtures to suit my needs whilst sorting this issue. Some tests fail with said updates though so I undid them. If someone with a better idea of how the fixtures should be configured (I just copy/pasted a previous version and incremented everything) wants to update them to set an alpha version as the latest that’d be appreciated (if we do indeed want to update the fixtures with this PR).
As things stand at the time of writing, these changes can be tested locally with
yarn run start:live
and the following URLs:maxVersion
is shown.Screenshot: