ITADN

Bundler 4.0.11 does not write its own digest in the `CHECKSUMS` section of the lockfile

#9512Opencallmesangio 创建于 2026-04-30
Bundler
C
callmesangiocommented
<!-- Thank you for contributing to the rubygems) repository, and specifically to the Bundler gem. Please fill in the following sections so we can process your issue as fast as possible --> ### Describe the problem as clearly as you can Hi, IIUC, bundler 4.0.11 should write its own digest in the `CHECKSUMS` section of Gemfile.lock. This was implemented in #9366 and it's also documented in the [changelog](https://blog.rubygems.org/2026/04/30/4.0.11-released.html), but I wasn't able to get it working. ### Did you try upgrading rubygems & bundler? Yes, I'm on 4.0.11 of both. <!-- Make sure you're using the latest version of both `bundler` and `rubygems`. Running `gem update --system` should get both installed on your system, and then `bundle update --bundler` should change your lockfile to use the new version of bundler that was just installed. It's likely that your issue has been fixed in recent versions, so just upgrading might do the trick, and will also save us some time :) --> ### Post steps to reproduce the problem Ruby is installed via mise. Bundler config: ```` $ bundle config list Settings are listed in order of priority. The top value will be used. clean Set for the current user (/Users/fabio/.bundle/config): true path Set for the current user (/Users/fabio/.bundle/config): ".bundle" ```` Versions: ```shell $ gem --version 4.0.11 ``` ```shell $ bundle --version 4.0.11 ``` ```shell $ ruby --version ruby 3.4.9 (2026-03-11 revision 76cca827ab) +PRISM [x86_64-darwin24] ``` <!-- Fill this with a list of steps maintainers can follow to reproduce your issue. Note that while you see this issue in your computer, maintainers might not see the same thing on theirs. There are many things that could influence this: * How your ruby is setup (OS package, from source, using a version manager). * How bundler & rubygems are configured. * The version of each involved piece of software that you are using. * ... The more complete the steps to simulate your particular environment are, the easier it will be for maintainers to reproduce your issue on their machines. Ideally, we recommend you set up the list of steps as a Dockerfile. A Dockerfile provides a neutral environment that should give the same results, no matter where it's run. --> ### Which command did you run? ```shell $ bundle init Writing new Gemfile to /Volumes/projects/new-ruby-project/Gemfile $ bundle add uri Fetching gem metadata from https://rubygems.org/. Resolving dependencies... Fetching gem metadata from https://rubygems.org/. Fetching uri 1.1.1 Installing uri 1.1.1 ``` <!-- Replace this with the specific command that is causing trouble. --> ### What were you expecting to happen? My expectation is that bundler should write its own digest in the lockfile. <!-- Replace this with the results you expected before running the command. --> ### What happened instead? The lockfile includes only the checksum of the installed gem. The same happens upgrading an existing project to bundler 4.0.11 via `bundler update --bundler`. ```` $ cat -p Gemfile.lock GEM remote: https://rubygems.org/ specs: uri (1.1.1) PLATFORMS ruby x86_64-darwin-24 DEPENDENCIES uri (~> 1.1) CHECKSUMS uri (1.1.1) sha256=379fa58d27ffb1387eaada68c749d1426738bd0f654d812fcc07e7568f5c57c6 BUNDLED WITH 4.0.11 ```` ### If not included with the output of your command, run `bundle env` and paste the output below ## Environment ``` Bundler 4.0.11 Platforms ruby, x86_64-darwin-24 Ruby 3.4.9p82 (2026-03-11 revision 76cca827ab52ab1d346a728f068d5b8da3e2952b) [x86_64-darwin-24] Full Path /Users/fabio/.local/share/mise/installs/ruby/3.4.9/bin/ruby Config Dir /Users/fabio/.local/share/mise/installs/ruby/3.4.9/etc RubyGems 4.0.11 Gem Home /Users/fabio/.local/share/mise/installs/ruby/3.4.9/lib/ruby/gems/3.4.0 Gem Path /Users/fabio/.gem/ruby/3.4.0:/Users/fabio/.local/share/mise/installs/ruby/3.4.9/lib/ruby/gems/3.4.0 User Home /Users/fabio User Path /Users/fabio/.gem/ruby/3.4.0 Bin Dir /Users/fabio/.local/share/mise/installs/ruby/3.4.9/bin Tools Git 2.54.0 RVM not installed rbenv not installed chruby not installed ``` ## Bundler Build Metadata ``` Timestamp 2026-04-30 Git SHA b7155a3865 ``` ## Bundler settings ``` clean Set for the current user (/Users/fabio/.bundle/config): true path Set for the current user (/Users/fabio/.bundle/config): ".bundle" ``` ## Gemfile ### Gemfile ```ruby # frozen_string_literal: true source "https://rubygems.org" # gem "rails" gem "uri", "~> 1.1" ``` ### Gemfile.lock ``` GEM remote: https://rubygems.org/ specs: uri (1.1.1) PLATFORMS ruby x86_64-darwin-24 DEPENDENCIES uri (~> 1.1) CHECKSUMS uri (1.1.1) sha256=379fa58d27ffb1387eaada68c749d1426738bd0f654d812fcc07e7568f5c57c6 BUNDLED WITH 4.0.11 ```
9 条评论