dependabot-cargo 0.203.0 → 0.204.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 +4 -4
- data/lib/dependabot/cargo/update_checker/version_resolver.rb +6 -13
- metadata +3 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 2c316667a86f0549971f8b65c79280f33a78397b87a40503bf6d66f0faa2fbde
|
|
4
|
+
data.tar.gz: 27c9226a6f36df466e0b2e320e9a22a74187010d73c266c20bc31f6a5d69a8e5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: fef84183b2b8aa896e50a9225a5a21688b98b0d093f3fda8ced4ce56ff9b2546769e5fb47cd3c8939d7dc5cbaf8be0734d9ea9abab8322e273e9058b88b0f058
|
|
7
|
+
data.tar.gz: 32d58bbb5d2ce798fd751407656bf1428e781bb0bfb743c9d772e67e4308b67097eb41155a6cbeb7a93263710361f6845a8de42c946d17a1137ea818bfdc0006
|
|
@@ -19,6 +19,7 @@ module Dependabot
|
|
|
19
19
|
OBJECT_PATTERN = /object not found - no match for id \(.*\)/.freeze
|
|
20
20
|
REF_NOT_FOUND_REGEX =
|
|
21
21
|
/#{UNABLE_TO_UPDATE}.*(#{REVSPEC_PATTERN}|#{OBJECT_PATTERN})/m.freeze
|
|
22
|
+
GIT_REF_NOT_FOUND_REGEX = /Updating git repository `(?<url>[^`]*)`.*fatal: couldn't find remote ref/m.freeze
|
|
22
23
|
|
|
23
24
|
def initialize(dependency:, credentials:,
|
|
24
25
|
original_dependency_files:, prepared_dependency_files:)
|
|
@@ -179,7 +180,6 @@ module Dependabot
|
|
|
179
180
|
|
|
180
181
|
# rubocop:disable Metrics/AbcSize
|
|
181
182
|
# rubocop:disable Metrics/PerceivedComplexity
|
|
182
|
-
# rubocop:disable Metrics/MethodLength
|
|
183
183
|
def handle_cargo_errors(error)
|
|
184
184
|
if error.message.include?("does not have these features")
|
|
185
185
|
# TODO: Ideally we should update the declaration not to ask
|
|
@@ -188,7 +188,8 @@ module Dependabot
|
|
|
188
188
|
end
|
|
189
189
|
|
|
190
190
|
if error.message.include?("authenticate when downloading repo") ||
|
|
191
|
-
error.message.include?("HTTP 200 response: got 401")
|
|
191
|
+
error.message.include?("HTTP 200 response: got 401") ||
|
|
192
|
+
error.message.include?("fatal: Authentication failed for")
|
|
192
193
|
# Check all dependencies for reachability (so that we raise a
|
|
193
194
|
# consistent error)
|
|
194
195
|
urls = unreachable_git_urls
|
|
@@ -204,17 +205,10 @@ module Dependabot
|
|
|
204
205
|
raise Dependabot::GitDependenciesNotReachable, urls
|
|
205
206
|
end
|
|
206
207
|
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
error.message.match(BRANCH_NOT_FOUND_REGEX).
|
|
210
|
-
named_captures.fetch("url").split(/[#?]/).first
|
|
211
|
-
raise Dependabot::GitDependencyReferenceNotFound, dependency_url
|
|
212
|
-
end
|
|
208
|
+
[BRANCH_NOT_FOUND_REGEX, REF_NOT_FOUND_REGEX, GIT_REF_NOT_FOUND_REGEX].each do |regex|
|
|
209
|
+
next unless error.message.match?(regex)
|
|
213
210
|
|
|
214
|
-
|
|
215
|
-
dependency_url =
|
|
216
|
-
error.message.match(REF_NOT_FOUND_REGEX).
|
|
217
|
-
named_captures.fetch("url").split(/[#?]/).first
|
|
211
|
+
dependency_url = error.message.match(regex).named_captures.fetch("url").split(/[#?]/).first
|
|
218
212
|
raise Dependabot::GitDependencyReferenceNotFound, dependency_url
|
|
219
213
|
end
|
|
220
214
|
|
|
@@ -245,7 +239,6 @@ module Dependabot
|
|
|
245
239
|
end
|
|
246
240
|
# rubocop:enable Metrics/AbcSize
|
|
247
241
|
# rubocop:enable Metrics/PerceivedComplexity
|
|
248
|
-
# rubocop:enable Metrics/MethodLength
|
|
249
242
|
|
|
250
243
|
def unreachable_git_urls
|
|
251
244
|
return @unreachable_git_urls if defined?(@unreachable_git_urls)
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dependabot-cargo
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.204.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dependabot
|
|
@@ -16,14 +16,14 @@ dependencies:
|
|
|
16
16
|
requirements:
|
|
17
17
|
- - '='
|
|
18
18
|
- !ruby/object:Gem::Version
|
|
19
|
-
version: 0.
|
|
19
|
+
version: 0.204.0
|
|
20
20
|
type: :runtime
|
|
21
21
|
prerelease: false
|
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
|
23
23
|
requirements:
|
|
24
24
|
- - '='
|
|
25
25
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: 0.
|
|
26
|
+
version: 0.204.0
|
|
27
27
|
- !ruby/object:Gem::Dependency
|
|
28
28
|
name: debase
|
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|