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

Add patch to Ruby version in dev.yml #1274

Merged
merged 1 commit into from
Nov 24, 2022
Merged

Conversation

sambostock
Copy link
Contributor

Motivation

With the patch, Dev downloads a precompiled binary, but without it seems to choose to compile from source, which seems unnecessary.

Implementation

The config is updated to Ruby 3.1.2, the latest in the 3.1 releases.

Tests

🎩'd locally.

@sambostock sambostock requested a review from a team as a code owner November 16, 2022 06:35
@sambostock
Copy link
Contributor Author

sambostock commented Nov 16, 2022

CI failures seem unrelated. I was able to push an empty commit based on main and replicate the failures.

It consistently fails only on the following test, only on builds using Rails 6.1:

Tapioca
  Gem
    Pipeline
      it compiles constants of generic types                            ERROR (0.02s)
Minitest::UnexpectedError:
  TypeError: T.let: Expected type GenericInterface[::Numeric],
                         got type Concrete with hash 4102188866738066998
    Caller: /tmp/d20...1mo/lib/generic.rb:16
            /tmp/d20...1mo/lib/generic.rb:16:in `<top (required)>'
            .../tapioca/lib/tapioca.rb:23:in `block in silence_warnings'
            [...]
            .../tapioca/spec/tapioca/gem/pipeline_spec.rb:3328:in `block (2 levels) in <class:PipelineSpec>'

Update: Resolving this is being worked on in #1270

@@ -3,7 +3,7 @@ name: tapioca
type: ruby

up:
- ruby: '3.1'
- ruby: '3.1.2'
Copy link
Collaborator

Choose a reason for hiding this comment

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

With the patch, Dev downloads a precompiled binary, but without it seems to choose to compile from source, which seems unnecessary.

Should we add this as a comment explaining why we use this version?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

🤷‍♂️ I've never seen it in other projects. This tends to be "latest stable" anyway.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Searching for x.y Ruby versions in dev.yml across our org only turns up 5 matches, so I think it's safe to say this is uncommon.

With the patch, Dev downloads a precompiled binary, but without it seems
to choose to compile from source, which seems unnecessary.
@sambostock sambostock merged commit c92a095 into main Nov 24, 2022
@sambostock sambostock deleted the patch-ruby-version-in-dev-yml branch November 24, 2022 20:44
@shopify-shipit shopify-shipit bot temporarily deployed to production December 19, 2022 22:14 Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants