arthurnn / twirp-ruby

Twirp services in Ruby
Apache License 2.0
155 stars 60 forks source link

Restrict faraday upper version range #126

Open shawnHartsell opened 2 months ago

shawnHartsell commented 2 months ago

Similar to https://github.com/arthurnn/twirp-ruby/pull/124

The current version range of faraday is set to < 3. This caused an error in our Twirp API CI/CD pipelines due to (what appears) to be a breaking change that was introduced between versions 2.11.0 and 2.12.0 of faraday (released today).

Specifically, it appears to be around an explicit json dependency added in 2.12.0 of the Gem. 2.12.0 release notes. We resolved the issue by explicitly requiring 2.11.0 of Faraday in our tooling.

I'm not intimately familiar in faraday's release process, so I can't speak to if introducing breaking changes in minor versions is normal for that lib. However, I think it would be good if we could protect consumers of twirp Ruby by being a bit more restrictive on the upper bound of the version range.

shawnHartsell commented 2 months ago

Below is the exact error message from one of our failing builds. We are currently using 1.10.0 of twirp-ruby

An error occurred while installing json (2.7.2), and Bundler cannot continue.

  In Gemfile:
  ****redacted-project was resolved to 1.0.0, which depends
  on
      twirp was resolved to 1.10.0, which depends on
        faraday was resolved to 2.12.0, which depends on
          json