-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Set 2.6 as minimum ruby version for Sinatra 3 #1699
Conversation
@@ -1,11 +1,4 @@ | |||
# frozen_string_literal: true | |||
$stderr.puts <<EOF if !Hash.method_defined?(:slice) && !$LOAD_PATH.grep(%r{gems/activesupport}).empty? && ENV['SINATRA_ACTIVESUPPORT_WARNING'] != 'false' |
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.
Hash#slice
was added in Ruby 2.5 so this if
is going to be false
always.
I like this suggestion 👍 |
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.
A thorough and careful update! Thanks, @epergo!
(Any RuboCop configuration that could get an update, too.)
@namusyaka Do you feel ready to merge this? |
* Run tests for Ruby versions >= 2.6 * Remove not needed checks for methods defined * Set required_ruby_version to >= 2.6 * Update READMEs with new Ruby versions
* Run tests for Ruby versions >= 2.6 * Remove not needed checks for methods defined * Set required_ruby_version to >= 2.6 * Update READMEs with new Ruby versions
* Run tests for Ruby versions >= 2.6 * Remove not needed checks for methods defined * Set required_ruby_version to >= 2.6 * Update READMEs with new Ruby versions
* Run tests for Ruby versions >= 2.6 * Remove not needed checks for methods defined * Set required_ruby_version to >= 2.6 * Update READMEs with new Ruby versions
Now that we have an
unstable
branch I think we can start doing these kind of changes. Ruby 2.5 support was dropped last March so I think that for the release of Sinatra 3.0 we could set the required minimum ruby version to 2.6 which will have support until March 2022.I have cleaned up the
indifferent_hash
implementation because we had a lot of conditionals to check if thehash
implementation of the installed ruby version had certain methods or not.WDYT?