dependabot-go_modules 0.401.0 → 0.402.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0b2b53bbb48b84ca1f7c5b2f62a63f38bc9fbd4862361827836b9f187c5a814a
4
- data.tar.gz: 06066f37ca5940ee83ee6073e7a8215201577e9da520163eda7b6bf30a6f6a25
3
+ metadata.gz: 1c052f4f5db8b010cd76d3626359a37799e1da3e6a2e8a95909764f4254918ba
4
+ data.tar.gz: e04068d807a4ad8f3febb620e8c3c18769ea553e47dd44258bd21e895e2c2aa8
5
5
  SHA512:
6
- metadata.gz: cd2e3b779771e3c92a07e7d609af95be7af592f47bd26c792735cb2d0685e1bb104586673103d6f07b861ece56994611dd1b43e362735f7413042480dcdbced8
7
- data.tar.gz: 8c16abde1c7c011714160a0f6bb99540356704b7d79ff50321d92d8f280a3fc890ec951342de4748e8609b3638bd384b4c647ddc3777f32b0b0addde94c2f766
6
+ metadata.gz: afc71ddb4ebee49031e1755946e69809ffc884d4301931f0920c8d7a3b75d43c29dc23ba0b2a831c2ce33f33de55e523f55532b329cc981979046d76a902251e
7
+ data.tar.gz: d971f9e7489aecf9a7129d11d8d5c31d5c8af794139c7967186d39cf71ae412c31487e9ef2308b4630ec69146005f29422cba4474be9e09d6df3dc08c448a499
@@ -252,6 +252,7 @@ module Dependabot
252
252
 
253
253
  run_go_work_sync
254
254
  run_workspace_tidy
255
+ run_go_list_modules
255
256
 
256
257
  collect_workspace_file_contents
257
258
  end
@@ -277,6 +278,20 @@ module Dependabot
277
278
  end
278
279
  end
279
280
 
281
+ # Go < 1.28 leaves go.work.sum without the checksums that `go list -m all` adds after `go work sync`
282
+ # (golang/go#63901). Loading the full module list last records them for the final workspace graph.
283
+ # Best-effort: sync and tidy have already succeeded, so a failure here must not fail the update.
284
+ sig { void }
285
+ def run_go_list_modules
286
+ return unless dependency_files.any? { |f| f.name == "go.work.sum" }
287
+
288
+ command = "go list -m all"
289
+ _, stderr, status = Open3.capture3(command)
290
+ return if status.success?
291
+
292
+ Dependabot.logger.info "Failed to `#{command}` in the workspace: #{stderr}"
293
+ end
294
+
280
295
  sig { returns(T::Array[String]) }
281
296
  def workspace_module_paths
282
297
  go_work_file = dependency_files.find { |f| f.name.end_with?("go.work") }
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dependabot-go_modules
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.401.0
4
+ version: 0.402.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dependabot
@@ -15,14 +15,14 @@ dependencies:
15
15
  requirements:
16
16
  - - '='
17
17
  - !ruby/object:Gem::Version
18
- version: 0.401.0
18
+ version: 0.402.0
19
19
  type: :runtime
20
20
  prerelease: false
21
21
  version_requirements: !ruby/object:Gem::Requirement
22
22
  requirements:
23
23
  - - '='
24
24
  - !ruby/object:Gem::Version
25
- version: 0.401.0
25
+ version: 0.402.0
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: debug
28
28
  requirement: !ruby/object:Gem::Requirement
@@ -277,7 +277,7 @@ licenses:
277
277
  - MIT
278
278
  metadata:
279
279
  bug_tracker_uri: https://github.com/dependabot/dependabot-core/issues
280
- changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.401.0
280
+ changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.402.0
281
281
  rdoc_options: []
282
282
  require_paths:
283
283
  - lib