slatedocs / slate

Beautiful static documentation for your API
https://slatedocs.github.io/slate
Apache License 2.0
36.01k stars 107 forks source link

ci: pinning build.yml rubygems-update version in GHA #1784

Closed tarilabs closed 7 months ago

tarilabs commented 8 months ago

Hi 👋

I'm using Slate for a documentation project and it's awesome! 🚀

Recently, I've started noticing GitHub Action failures for Build job with the following error:

Run gem update --system
ERROR:  Error installing rubygems-update:
    There are no versions of rubygems-update (= 3.5.4) compatible with your Ruby & RubyGems
    rubygems-update requires Ruby version >= 3.0.0. The current ruby version is 2.7.8.225.

This happens when ruby-version from matrix in build.yml is 2.6 or 2.7 etc.

At the time of writing, the latest rubygems-update compatible with ruby 2.6 is: 3.4.22 (see here)

Any rubygems-update from 3.5.x (at the time of writing, latest is 3.5.4) requires ruby >= 3.0.0 making this build.yml to fail.

Pinning rubygems-update to 3.4.22 for the GHA ci scope solved our Build GHA runs; proposing the same here if that helps other Slate users, or looking forward to hearing improving feedback for alternative (or more proper?) solution.

MasterOdin commented 7 months ago

Hi @tarilabs, thanks for your interest in contributing to slate, though unfortunately I'm going to close this PR! Per the comment above the step, I had originally added this to fix a bug that was present when using Ruby 2.3 on GHA. Given that support for that was dropped years ago, I think it's better to just remove this shim and use whatever version of gem comes with GHA for now, which was done in #1787, simplifying the CI to boot.