This seems a bit crazy. Why might it be that I can't update rubygems? It says my ruby version is too old, and that the correct ruby version is... the version I am using!
bundle -v
# => Bundler version 2.4.22
ruby -v
# => ruby 3.3.3 (2024-06-12 revision f1c7b6f435) [x86_64-linux]
gem update --system
# => Latest version already installed. Done.
gem update --system 2.6.9
# => ERROR: rubygems 2.6.9 is not supported on 3.3.3. The oldest version supported by this ruby is 3.3.3
type bundle
# => bundle is hashed (/home/me/.gem/ruby/3.3.3/bin/bundle)
type ruby
# => ruby is hashed (/home/me/.rubies/ruby-3.3.3/bin/ruby)
It seems you might just be misreading the error message.
You are trying to use ruby 3.3.3 but downgrade rubygems to version 2.6.9.
The error is telling you that the oldest supported version of rubygems is 3.3.3 when using ruby 3.3.3.
A clarifying error might read something like this:
ERROR: rubygems 2.6.9 is not supported on [ruby] 3.3.3. The oldest version [of rubygems] supported by
thisruby [3.3.3] is [rubygems] 3.3.3
Comments from the Source Code
Oldest version we support downgrading to. This is the version that originally ships with the oldest supported patch version of ruby.