-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Warn on empty or open required_ruby_version specification attribute. #5010
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
|
I really like this! 👍 |
|
I really like it 🔥 This is a bit tangential, but I wonder If it would make sense to enforce a minimal ruby version based on what ruby version is supported by rubygems/bundler. I could see this being problematic if we prevent security patches to gems, but I'm not sure how much that is a concern. |
|
@doodzik That seems a bit too much to me. I think there's a variety of reasons why people still support old rubies in their gems, and I think completely forbidding it might have the effect of discouraging people from upgrading rubygems/bundler. |
|
What's left to do here? |
|
Warning text is currently just a placeholder. Feel free to suggest better. |
2d88804 to
ded2a57
Compare
doodzik
left a comment
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.
LGTM
deivid-rodriguez
left a comment
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.
Awesome!
|
@simi Can you merge this? I'd like to merge for Ruby 3.3.0-preview2. |
|
I'm out for next two weeks. Feel free to merge.
Dne út 8. 8. 2023 12:20 uživatel Hiroshi SHIBATA ***@***.***>
napsal:
… @simi <https://github.com/simi> Can you merge this? I'd like to merge for
Ruby 3.3.0-preview2.
—
Reply to this email directly, view it on GitHub
<#5010 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABPLEBREPJOSGEDMO34K5LXUIHFDANCNFSM5GUB2SPQ>
.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
ded2a57 to
7f07c4f
Compare
|
I'll handle this for RubyGems 3.6 and Ruby 3.4. |
7f07c4f to
9c2d1e6
Compare
cd2ab99 to
c418947
Compare
|
rebased @hsbt |
c418947 to
e4bb337
Compare
hsbt
left a comment
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.
@simi Thank you!
Warn on empty or open required_ruby_version specification attribute. (cherry picked from commit 1aa7252)
This is just concept what we can do to improve situation of filled in
required_ruby_versionvalue to prevent problems described in rubygems/rfcs#34.I have used placeholder text for now. Feel free to suggest better. We can also use different text for different situations.
ℹ️
required_ruby_versionis already part ofbundle gemtemplate based on this logic.https://github.com/rubygems/rubygems/blob/2f48d60afe050862258212d0c68530f39fb5fdfa/bundler/lib/bundler/cli/gem.rb#L407-L414
Later on we can move this attribute to required. It could be also possible to warn on "potentially misused values". For example when newer Ruby is used to build gem (then the minimal), we can inform user to ensure it is good idea to check if gem is still compatible with minimal Ruby version.
related to rubygems/guides#295, rubygems/rfcs#34 and rubygems/rfcs#26
/cc @marcandre