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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
馃摚 Plan for Ruby 3.0 support (Released!) #17931
Comments
This comment has been minimized.
This comment has been minimized.
With those commands, I got some warnings that need to be fixed for Ruby 3.0 (including other normal warnings). https://gist.github.com/ainame/d7f1c4d2fb07f139d3a0f064d4cbda75 I'll be fixing them and sending PRs once #17861 gets merged. Maybe I should create a Danger lint rule to check if there are such warnings appearing on rspec output. |
I'm accumulating fixes onto this branch. |
I recognize this is off-topic but it doesn't appear there are too many subscribers - just wanted to say thanks! open source maintenance is usually a thankless job but shouldn't be, and fastlane in particular is so useful to me, thanks for helping. Cheers @ainame |
This PR will be the one to 馃敧 deprecated warnings as much as I found in fastlane itself and I could fix.
I identified that It's an off topic but I realised |
I realised that without keeping monitoring warnings, there may be regressions of my fixes for warnings. So I will work on Danger checks for it. Added this to the TODO list.
|
This is done. |
Just here to cheer everyone on! Looking forward to a 3.0-compatible release. :) |
This PR is now ready to review! 馃殌 It took me a while to implement a CI check that prevents regressions without using Danger. It turned out we won't be able to enable Danger for forked repositories as it can leak GitHub's access token. |
#18021 has got merged. From now on no new code that is not ready for Ruby 3.0 in terms of "Separation of positional and keyword arguments" can be merged. It will be prevented by CI as far as it's covered by unit tests. And also @joshdholtz the lead maintainer and I discussed dropping Ruby 2.4 support. We'd like to drop 2.4 support when we officially release "Ruby 3.0" support. It's mainly because rubygems we are using also did the same. So the more rubygems do that the harder we keep supporting old versions; e.g. #18339. Essentially the Ruby core team has ended security support for 2.4 last year. It's good to update your Ruby version to keep your environment secure. googleapis/google-api-ruby-client#2841 |
Replacement of
|
Bumping |
highline 1.7.x is not compatible with Ruby 3.0. I'll be migrating it to 2.x. |
In order to update |
You are on the ultimate yak shave @ainame :-), thanks so much for your work here |
@mikehardy It's my pleasure. Yeah, it is yak shaving but that's the only way to get things done right here馃槀 |
I will work on https://github.com/googleapis/google-api-ruby-client/blob/master/google-api-client/OVERVIEW.md |
This PR is ready to review and test! I appreciate it if anyone can volunteer to test the below branch as it updates
|
This comment has been minimized.
This comment has been minimized.
On a different machine a brew update today gave me a new gcc/llvm/etc (which was hinted at as a resolution for my issue in the comment I hid, above) and I was able to successfully create a Gemfile with your git source above and run I ran I suspect that with the google-apis being the thing you really want to test, someone that uses Fastlane to interact with the Play Store would be your ideal test scenario yes? Hopefully someone else can give that a test, but I can verify at least for a typical TestFlight / iOS build scenario, there is no regression Thanks for your continued effort in this area, looking forward to ruby 3 support when it's ready 馃槂 |
@mikehardy Thank you for giving it a try. Your feedback using my branch with real-world |
Hello, there馃憢 It's going to be released tommorrow! |
It's released! 馃帀 I'll leave this issue open for a while to gather further feedback regarding Ruby 3.0. Note that there is a known issue where |
Issues in supply were resolved now |
There will be a breaking change in Ruby 3.1.0 due to It's reported here #18768
I'll submit a PR to |
This will also be broken with psych v4.0. We need to use keyword arguments for fastlane/spaceship/lib/spaceship/spaceauth_runner.rb Lines 42 to 47 in 27dfa59
|
It's been a while since released. I'm going to close this ticket. |
馃憢 Hello, fastlane community!
Ruby 3.0 support was released at v2.183.0. Please give it a try and give us feedback on this issue.
https://github.com/fastlane/fastlane/releases/tag/2.183.0
The plan is now hidden under "Details".
Please react with 馃憤 emoji on this issue if you are waiting for Ruby 3.0 support!
This is @ainame who recently became a core contributor 馃殌 I'm pleased to announce that I will be working on getting Ruby 3.0 support in fastlane. So this ticket is to track the progress and let fastlane users be aware of the work being addressed.
TL; DR
Ruby 3.0 and currently supported versions
Ruby 3.0 was released on 25th December 2020. It's a major version update but its source code compatibility with 2.x should be good. There are performance improvements and interesting new features implemented.
However, fastlane hasn't officially supported Ruby 3.0 yet. Please read the below section for details. The currently supported versions are Ruby 2.4-2.7. I highly recommend that you upgrade Ruby version to 2.6 or 2.7. Ruby 2.4 is now in EOL period, which means there will be no security fix for it. Ruby 2.5 will be the same soon.
https://www.ruby-lang.org/en/downloads/branches/
If you try to install fastlane against Ruby 3.0, it actually succeeds with the version "2.54.1" BUT it is too old and
deliver
won't work for the latest App Store Connect APIs. Please don't use it.How far is fastlane away from Ruby 3.0?
Ruby 2.7's warnings
Before going to Ruby 3.0, we should make sure the last version in 2.x series "2.7" is supported correctly. It's very important because 2.7 warns us if there are chances of breaking with some deprecation messages to prepare Ruby 3.0 migration. #15856
It's been recognised, in fact, fastlane can run on Ruby 2.7, which is the latest version in 2.x series. However, despite the fact, fastlane project hasn't guaranteed that all the testing specs pass with Ruby 2.7 on CI yet. This will be resolved on #17861
Blocker to install fastlane to Ruby 3.0
Right now, we have the dependency
google-api-client
that we have a strict limit in the flexibility of version resolving.However, within those versions, none of them allows us to install it to Ruby 3.0 env. We need to adopt 0.44.2 or later googleapis/google-api-ruby-client#900.
Replace unmaintained gem
There is also
slack-notifier
gem which was popular to send messages to Slack but however, it doesn't seem to be actively maintained. So we might need to replace that gem with other or one made by ourselves.To run unit tests
rspec/spec-mocks
rspec/rspec-mocks#1394 also still has some issues for Ruby 3.0. We need to wait for it to be fixed.Drop Ruby 2.4 support
We'd like to drop 2.4 support when we officially release "Ruby 3.0" support. It's mainly because rubygems we are using also did the same. So the more rubygems do that the harder we keep supporting old versions; e.g. #18339. Essentially the Ruby core team has ended security support for 2.4 last year. So it's good to update your Ruby version to keep your environment secure.
googleapis/google-api-ruby-client#2841
googleapis/signet#178
Todo
This is a rough plan to work on the migration.
Enable CI for Ruby 2.7[CI] support Ruby 2.7 on Circle CI聽#17861~PrepareDangera CI check to prevent master/main branch to cause regressions of 2.7 warnings before enabling Ruby 3.0 on CircleCI [Ruby 3.0] Fix Ruby 2.7's deprecation warnings聽#18021Fix warnings in the codebase [Ruby 3.0] Fix Ruby 2.7's deprecation warnings聽#18021Replace[Ruby 3.0] improve specs for Slack action 聽#18512 [Ruby 3.0] replace slack-notifier gem with internal library聽#18537slack-notifier
with something else or implement a basic Slack integration by ourselvesWait forApparently, we fixed this issue before I know itrspec-mocks
to release a version that supports Ruby 3.0 or fix existing specs that crashes due to Ruby 3.0 syntaxUpdate rubocop version to the latest[Ruby 3.0] Bump rubocop version聽#18564Update dependencies that have deprecation warnings; highline, etc...[Ruby 3.0] Switch back to the original commander gem and update dependencies聽#18599Bump[Ruby 3.0] Migrate google-api-client gem and drop Ruby 2.4聽#18656google-api-client
version to unblock Ruby 3.0 installationFix failing specs due to rspec's syntax unless rspec team releases a new version that supports Ruby 3.0Enable CI for Ruby 3.0[Ruby 3.0] Migrate google-api-client gem and drop Ruby 2.4聽#18656Release the version that supports Ruby 3.0 officiallyFor 3-5, depending on how big impact changes will have, we might cut a work branch to stack up changes and release RC branch. If it will not be too big, changes will be merged into
master
gradually.The text was updated successfully, but these errors were encountered: