-
Notifications
You must be signed in to change notification settings - Fork 1.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
Upgrade Ruby to version 2.7.4 #4662
Conversation
Note this version includes Bundler 2, so we can finally upgrade.
We were getting hundreds of "warning: URI.escape is obsolete" messages. So we're using `URI::DEFAULT_PARSER.escape` instead. IMHO it's OK to add this monkey-patch because we're replacing Paperclip with Active Storage, and when we finish with that we'll delete this file.
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.
Hi, @javierm
As ruby 2.7 already includes bundler version 2 I wonder if we may delete the line 38 from the Dockerfile. Same with /bin/setup#L17 and /bin/update#L17 🤔
The Dockerfile seems to work fine when running docker build -t consul .
without the mentioned line.
@Senen It looks like we could have actually done so after upgrading to Ruby 2.6 🤔. But, yes, now it's a good moment 👍. I've updated the pull request changing the Dockerfile. I'm not so sure about the other two, since those are scripts automatically generated by Rails and use the time gem install bundler --conservative
=> gem install bundler --conservative 0,42s user 0,16s system 114% cpu 0,508 total I'm usually fond of deleting code that does nothing, but since this is an external script and every time we upgrade to a new Rails version we'd have to remember to remove this line, I'd vote for leaving it like that. |
8982dc7
to
f087d6f
Compare
I think we could have already done so when upgrading Ruby to version 2.6.x (which also included the Bundler gem), but since we didn't, now that we've upgraded to Bundler 2.x it's probably a good moment.
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.
💎
Objectives
Notes
Ruby 2.7 introduced a separation of positional and keyword arguments, which caused warnings on almost every existing gem. This was solved by silencing those warnings in Ruby 2.7.2. However, before merging this pull request we're still going to update as many gems as possible and check the warnings in order to study how hard it will be to upgrade to Ruby 3.