Skip to content

Update Ruby to 3.1.7#68585

Merged
Hamms merged 9 commits into
stagingfrom
elijah/ruby-3.1.7
Oct 29, 2025
Merged

Update Ruby to 3.1.7#68585
Hamms merged 9 commits into
stagingfrom
elijah/ruby-3.1.7

Conversation

@Hamms

@Hamms Hamms commented Sep 26, 2025

Copy link
Copy Markdown
Contributor

Just pick up all patches to our current minor version of Ruby. Mostly doing this as part of general maintenance best practices, but we've also been eyeballing solid_queue for some future work, which requires Ruby >=3.1.6

Links

Previous update:

Testing story

Verified locally, in drone, and on an adhoc that the site builds and all tests pass.

I also verified that an existing server can successfully apply this change as an update. Specifically, I:

  1. created an adhoc based on staging
  2. merged this branch into that adhoc's branch
  3. manually updated the chef attributes in /var/chef/nodes/ to match
  4. manually ran sudo chef-client -o cdo-apps

Deployment strategy

Given that this is a patch update, I don't anticipate anywhere near the level of fragility we usually plan for with a Ruby update. I think this one should be fine to just send through our build pipeline as a normal PR.

Follow-up work

Next in our sights: Ruby 3.2

@Hamms Hamms added the Ruby Update Everything related to work to update the version of Ruby our codebase runs on label Sep 26, 2025
@Hamms Hamms changed the base branch from staging to elijah/bundle-deployment-mode-in-drone October 13, 2025 18:19
@Hamms Hamms changed the base branch from elijah/bundle-deployment-mode-in-drone to staging October 23, 2025 18:32
@Hamms Hamms force-pushed the elijah/ruby-3.1.7 branch from 95053da to d9af307 Compare October 23, 2025 19:05
@Hamms Hamms changed the title update Ruby to 3.1.7 Update Ruby to 3.1.7 Oct 23, 2025
@Hamms

Hamms commented Oct 27, 2025

Copy link
Copy Markdown
Contributor Author

@cat5inthecradle Heads up that I ended up incorporating the switch to cdo-ci for the Docker image tag (as recommended by #57243) into this PR. Let me know if you'd prefer to do that in a standalone PR, rather than bundling it up with this Ruby version change.

@Hamms Hamms marked this pull request as ready for review October 27, 2025 23:43
@Hamms Hamms requested a review from a team as a code owner October 27, 2025 23:43
@Hamms Hamms requested a review from snickell October 27, 2025 23:44

@snickell snickell left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I'm happy with switching docker tags in this PR, doing it in a separate PR would sorta just feel like make-work to me.

Comment thread docker/ci/Dockerfile
rbenv install 3.1.7 && \
eval "$(rbenv init -)" && \
rbenv shell 3.1.0 && \
rbenv shell 3.1.7 && \

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

It'd be nice if we could just ADD .ruby-version and use that here, but we build this with the wrong directory context. Oh well.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Yeah, it would in general be nice if we had some kind of single source of truth for the versions we target. I have more than once genuinely considered doing something like:

rbenv install $(curl https://raw.githubusercontent.com/code-dot-org/code-dot-org/refs/heads/staging/.ruby-version)

But fortunately I've always managed to talk myself down 😅

@cat5inthecradle cat5inthecradle 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.

LGTM! One PR sounds good, goodbye old too-optimistically named image 👋

@Hamms Hamms merged commit 00aa9fb into staging Oct 29, 2025
6 checks passed
@Hamms Hamms deleted the elijah/ruby-3.1.7 branch October 29, 2025 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Ruby Update Everything related to work to update the version of Ruby our codebase runs on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants