Skip to content
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

Enforce that CI matrix contains required_ruby_version & .ruby-version #3248

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

sambostock
Copy link
Contributor

Motivation

Our CI matrix should always include, at least:

  • the Ruby version being used in development, as specified in .ruby-version, and
  • the minimum Ruby version we support according to required_ruby_version in ruby-lsp.gemspec

#2017 dropped Ruby 3.0 from the CI matrix without changing the requirement in the gemspec.

Implementation

This adds a pair of tests to enforce all CI matrix ruby: [...] entries contain the Ruby versions listed

  • as the development Ruby version in .ruby-version, and
  • as the required_ruby_version in ruby-lsp.gemspec.

Ruby 3.0 is also added back to the CI matrix, which gets the test passing again.

There should be no consumer facing changes. If we do want to remove Ruby 3.0 again, then that belongs in a separate PR which also changes the ruby-lsp.gemspec (and is probably a major version bump).

Automated Tests

Yes, see above.

This ensures if the version is bumped in development, it is also added
to the matrix.
We should always test against the minimum Ruby version we support, and
it shouldn't be removed without also bumping the `required_ruby_version`
in the gemspec.
@sambostock sambostock requested a review from a team as a code owner February 26, 2025 18:07
Copy link

graphite-app bot commented Feb 26, 2025

How to use the Graphite Merge Queue

Add the label graphite-merge to this PR to add it to the merge queue.

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

- Bundler 2.6 requires Ruby 3.1
- Tapioca > 0.14 requires Ruby 3.1

I've changed `BUNDLED WITH` to the latest version in the 2.5 series,
which supports Ruby 3.0, and I've removed the version requirement on
`tapioca` (and run `bundle update`).

Let's see if this passes CI...
@sambostock sambostock force-pushed the enforce-ci-matrix-ruby-versions branch from b579687 to 808e375 Compare February 26, 2025 18:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant