Dont warn on prerelease dependencies with less than ("<")#2323
Dont warn on prerelease dependencies with less than ("<")#2323deivid-rodriguez wants to merge 2 commits intoruby:masterfrom
Conversation
|
In bundler, this sort of requirement will start allowing pre-releases |
|
I don't understand, can you elaborate? |
|
Elaborating myself, note that this is only removing a warning message in some cases where I think doesn't make sense. It's not changing behavior other than that. |
|
Right, but if you have |
|
What I’m trying to say is that a prerelease requirement in a < is just as “harmful” as with any other operator |
|
Ok, so I don't understand then. If I specify |
I believe that is the case, though I could be wrong |
|
I think you might be wrong, yeah. I just tried it and got: And then running If I change the dependency to |
|
This warning might be confusing and not very easy to understand / agree with, so we might consider entirely dropping it as you suggested in #2228 (comment). But if the warning stays, I think this PR should go in. |
|
I opened #2351 as a (better, I think) alternative. |
|
closing in favor of #2351 |
Remove semver gem build warning # Description: This is an alternative to #2323. I think this warning is too brittle at the moment because `rubygems` has no way of knowing if a dependency is semantically versioned. If a dependency is not semantically versioned, I don't see the problem with using something like `~> 1.2.3` so suggesting a constraint that does the same thing in a more complicated way just because it does not warn seems no good. In the future maybe rubygems could provide a `spec.versioning_policy =` accessor where gems can inform of their own versioning (`:semver`, or others) but currently I think this warning should just go. ______________ # Tasks: - [x] Describe the problem / feature - [ ] Write tests - [x] Write code to solve the problem - [ ] Get code review from coworkers / friends I will abide by the [code of conduct](https://github.com/rubygems/rubygems/blob/master/CODE_OF_CONDUCT.md).
Description:
I just saw this warning when installing my gem:
I can see the rationale for the "prerelease warning" but doesn't look reasonable when the requirement is using "<", since in that case we're filtering out prereleases. Right?
Tasks:
I will abide by the code of conduct.