Skip to content

THRIFT-6154: Drop Ruby 2.7 support - #3742

Merged
kpumuk merged 1 commit into
apache:masterfrom
kpumuk:rb-drop-ruby-2-7
Aug 24, 2026
Merged

THRIFT-6154: Drop Ruby 2.7 support#3742
kpumuk merged 1 commit into
apache:masterfrom
kpumuk:rb-drop-ruby-2-7

Conversation

@kpumuk

@kpumuk kpumuk commented Aug 24, 2026

Copy link
Copy Markdown
Member

Ruby 2.7 was released on December 25, 2019 and reached end of life on March 31, 2023, but the Thrift Ruby gem still declares and tests Ruby 2.7 support.

This raises the gem's minimum Ruby version to 3.0 and aligns the language matrix, Ruby documentation, RuboCop target, build matrix, and static-analysis workflow. The pure-Ruby CI variant moves to the new minimum instead of being removed.

The updated lint target also exposes a few behavior-preserving idiomatic cleanups: direct collection mapping, an endless range for partial socket writes, removal of a redundant regexp freeze, and removal of obsolete gemspec boilerplate.

This is a breaking support-policy change. Applications still running Ruby 2.7 must remain on an earlier Thrift gem until they upgrade Ruby.

  • Did you create an Apache Jira ticket? (THRIFT-6154)
  • If a ticket exists: Does your pull request title follow the pattern "THRIFT-NNNN: describe my issue"?
  • Did you squash your changes to a single commit? (not required, but preferred)
  • Did you do your best to avoid breaking changes? If one was needed, did you label the Jira ticket with "Breaking-Change"?
  • If your change does not involve any code, include [skip ci] anywhere in the commit message to free up build resources.

Copilot AI lite review requested due to automatic review settings August 24, 2026 00:49
@mergeable mergeable Bot added ruby Pull requests that update Ruby code github_actions Pull requests that update GitHub Actions code labels Aug 24, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the Apache Thrift Ruby library and CI configuration to drop Ruby 2.7 support (EOL) and set Ruby 3.0 as the minimum supported Ruby version, aligning documentation, linting, and GitHub Actions matrices accordingly.

Changes:

  • Raise the Ruby gem minimum required Ruby from >= 2.7.0 to >= 3.0.0.
  • Update Ruby-facing documentation and repo support-matrix references to Ruby 3.0+.
  • Update RuboCop and GitHub Actions workflows to remove Ruby 2.7 and use Ruby 3.0 for the minimum/pure-Ruby CI variant; includes small Ruby 3.0+ idiomatic cleanups.

Reviewed changes

Copilot reviewed 9 out of 9 changed files in this pull request and generated no comments.

Show a summary per file
File Description
lib/rb/thrift.gemspec Bumps required_ruby_version to >= 3.0.0 and removes obsolete gemspec boilerplate.
lib/rb/README.md Updates documented Ruby compatibility/requirements to Ruby 3.0+.
lib/rb/lib/thrift/uuid.rb Removes redundant regexp .freeze under the new Ruby baseline.
lib/rb/lib/thrift/transport/socket.rb Uses Ruby 3.0+ endless range slicing in partial-write loop.
lib/rb/lib/thrift/struct_union.rb Uses map for collection formatting (behavior-preserving cleanup).
lib/rb/.rubocop.yml Raises RuboCop TargetRubyVersion to 3.0.
LANGUAGES.md Updates Ruby language-level entry to reflect the new supported baseline.
.github/workflows/sca.yml Runs Ruby SCA job on Ruby 3.0 instead of 2.7.
.github/workflows/build.yml Removes Ruby 2.7 from the Ruby CI matrix and moves the no-extension job to Ruby 3.0.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Client: rb

Co-Authored-By: OpenAI Codex (GPT-5.6) <codex@openai.com>
Copilot AI review requested due to automatic review settings August 24, 2026 00:56

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 1 comment.

Comment thread lib/rb/README.md
@kpumuk
kpumuk merged commit 6320b0b into apache:master Aug 24, 2026
146 of 151 checks passed
@kpumuk
kpumuk deleted the rb-drop-ruby-2-7 branch August 24, 2026 11:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking change github_actions Pull requests that update GitHub Actions code ruby Pull requests that update Ruby code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants