dependabot-cargo 0.119.0.beta1 → 0.119.4
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/file_fetcher.rb +3 -2
- data/lib/dependabot/cargo/file_parser.rb +2 -0
- data/lib/dependabot/cargo/file_updater/lockfile_updater.rb +2 -0
- data/lib/dependabot/cargo/file_updater/manifest_updater.rb +1 -1
- data/lib/dependabot/cargo/requirement.rb +0 -2
- data/lib/dependabot/cargo/update_checker/file_preparer.rb +2 -0
- data/lib/dependabot/cargo/update_checker/version_resolver.rb +5 -1
- metadata +10 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6e6fe577f29137d26d131d38ad917663c2fd3db5bdbdb6b4e25293f3fa92fa72
|
4
|
+
data.tar.gz: 1b5a2685da24284552d48d1a8eb41776b16d8bf13218b379a5ebb583913f57f2
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 68f549929a400c17c492f4c3e870593641f18ea0f133050f40e057a92d09ae52dcc1fe3cb29a1b3ee8d25a5472549218c815f17460f8e2d36b7850f75dff42de
|
7
|
+
data.tar.gz: fba52f77c819658c68f339bf26386e13ece02093c5a698875f8da84949b11d33391b4d8e547eb94673d3d4b06552f0e483830e9fed15751815c396f0721afddc
|
@@ -218,6 +218,7 @@ module Dependabot
|
|
218
218
|
# an alternative source (i.e., a git source) is also specified
|
219
219
|
# rubocop:disable Metrics/CyclomaticComplexity
|
220
220
|
# rubocop:disable Metrics/PerceivedComplexity
|
221
|
+
# rubocop:disable Metrics/AbcSize
|
221
222
|
def required_path?(file, path)
|
222
223
|
# Paths specified in dependency declaration
|
223
224
|
Cargo::FileParser::DEPENDENCY_TYPES.each do |type|
|
@@ -254,9 +255,9 @@ module Dependabot
|
|
254
255
|
|
255
256
|
false
|
256
257
|
end
|
257
|
-
|
258
|
-
# rubocop:enable Metrics/CyclomaticComplexity
|
258
|
+
# rubocop:enable Metrics/AbcSize
|
259
259
|
# rubocop:enable Metrics/PerceivedComplexity
|
260
|
+
# rubocop:enable Metrics/CyclomaticComplexity
|
260
261
|
|
261
262
|
def expand_workspaces(path)
|
262
263
|
path = Pathname.new(path).cleanpath.to_path
|
@@ -56,6 +56,7 @@ module Dependabot
|
|
56
56
|
raise Dependabot::DependencyFileNotEvaluatable, msg
|
57
57
|
end
|
58
58
|
|
59
|
+
# rubocop:disable Metrics/PerceivedComplexity
|
59
60
|
def manifest_dependencies
|
60
61
|
dependency_set = DependencySet.new
|
61
62
|
|
@@ -82,6 +83,7 @@ module Dependabot
|
|
82
83
|
|
83
84
|
dependency_set
|
84
85
|
end
|
86
|
+
# rubocop:enable Metrics/PerceivedComplexity
|
85
87
|
|
86
88
|
def build_dependency(name, requirement, type, file)
|
87
89
|
Dependency.new(
|
@@ -68,6 +68,7 @@ module Dependabot
|
|
68
68
|
|
69
69
|
# rubocop:disable Metrics/PerceivedComplexity
|
70
70
|
# rubocop:disable Metrics/CyclomaticComplexity
|
71
|
+
# rubocop:disable Metrics/AbcSize
|
71
72
|
def better_specification_needed?(error)
|
72
73
|
return false if @custom_specification
|
73
74
|
return false unless error.message.match?(/specification .* is ambigu/)
|
@@ -96,6 +97,7 @@ module Dependabot
|
|
96
97
|
@custom_specification = spec_options.first
|
97
98
|
true
|
98
99
|
end
|
100
|
+
# rubocop:enable Metrics/AbcSize
|
99
101
|
# rubocop:enable Metrics/CyclomaticComplexity
|
100
102
|
# rubocop:enable Metrics/PerceivedComplexity
|
101
103
|
|
@@ -101,7 +101,7 @@ module Dependabot
|
|
101
101
|
simple_declaration_regex =
|
102
102
|
/(?:^|["'])#{Regexp.escape(simple_declaration)}/
|
103
103
|
content.gsub(simple_declaration_regex) do |line|
|
104
|
-
line.gsub(old_req
|
104
|
+
line.gsub(/.+=.*\K(#{old_req})/, new_req)
|
105
105
|
end
|
106
106
|
elsif content.match?(feature_declaration_version_regex(dep))
|
107
107
|
content.gsub(feature_declaration_version_regex(dep)) do |part|
|
@@ -53,8 +53,6 @@ module Dependabot
|
|
53
53
|
private
|
54
54
|
|
55
55
|
def convert_rust_constraint_to_ruby_constraint(req_string)
|
56
|
-
req_string = req_string
|
57
|
-
|
58
56
|
if req_string.include?("*")
|
59
57
|
ruby_range(req_string.gsub(/(?:\.|^)[*]/, "").gsub(/^[^\d]/, ""))
|
60
58
|
elsif req_string.match?(/^~[^>]/) then convert_tilde_req(req_string)
|
@@ -201,6 +201,7 @@ module Dependabot
|
|
201
201
|
lower_bound_req + ", <= #{latest_allowable_version}"
|
202
202
|
end
|
203
203
|
|
204
|
+
# rubocop:disable Metrics/PerceivedComplexity
|
204
205
|
def lower_bound_version
|
205
206
|
@lower_bound_version ||=
|
206
207
|
if git_dependency? && git_dependency_version
|
@@ -220,6 +221,7 @@ module Dependabot
|
|
220
221
|
version_from_requirement || 0
|
221
222
|
end
|
222
223
|
end
|
224
|
+
# rubocop:enable Metrics/PerceivedComplexity
|
223
225
|
|
224
226
|
def git_dependency_version
|
225
227
|
return unless lockfile
|
@@ -15,8 +15,10 @@ module Dependabot
|
|
15
15
|
/Unable to update (?<url>.*?)$/.freeze
|
16
16
|
BRANCH_NOT_FOUND_REGEX =
|
17
17
|
/#{UNABLE_TO_UPDATE}.*to find branch `(?<branch>[^`]+)`/m.freeze
|
18
|
+
REVSPEC_PATTERN = /revspec '.*' not found/.freeze
|
19
|
+
OBJECT_PATTERN = /object not found - no match for id \(.*\)/.freeze
|
18
20
|
REF_NOT_FOUND_REGEX =
|
19
|
-
/#{UNABLE_TO_UPDATE}.*
|
21
|
+
/#{UNABLE_TO_UPDATE}.*(#{REVSPEC_PATTERN}|#{OBJECT_PATTERN})/m.freeze
|
20
22
|
|
21
23
|
def initialize(dependency:, credentials:,
|
22
24
|
original_dependency_files:, prepared_dependency_files:)
|
@@ -80,6 +82,7 @@ module Dependabot
|
|
80
82
|
|
81
83
|
# rubocop:disable Metrics/PerceivedComplexity
|
82
84
|
# rubocop:disable Metrics/CyclomaticComplexity
|
85
|
+
# rubocop:disable Metrics/AbcSize
|
83
86
|
def better_specification_needed?(error)
|
84
87
|
return false if @custom_specification
|
85
88
|
return false unless error.message.match?(/specification .* is ambigu/)
|
@@ -108,6 +111,7 @@ module Dependabot
|
|
108
111
|
@custom_specification = spec_options.first
|
109
112
|
true
|
110
113
|
end
|
114
|
+
# rubocop:enable Metrics/AbcSize
|
111
115
|
# rubocop:enable Metrics/CyclomaticComplexity
|
112
116
|
# rubocop:enable Metrics/PerceivedComplexity
|
113
117
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dependabot-cargo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.119.
|
4
|
+
version: 0.119.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dependabot
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-09-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: dependabot-common
|
@@ -16,14 +16,14 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - '='
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: 0.119.
|
19
|
+
version: 0.119.4
|
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.119.
|
26
|
+
version: 0.119.4
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: byebug
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
@@ -100,14 +100,14 @@ dependencies:
|
|
100
100
|
requirements:
|
101
101
|
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: 0.
|
103
|
+
version: 0.90.0
|
104
104
|
type: :development
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
108
|
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: 0.
|
110
|
+
version: 0.90.0
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: vcr
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
@@ -161,7 +161,7 @@ homepage: https://github.com/dependabot/dependabot-core
|
|
161
161
|
licenses:
|
162
162
|
- Nonstandard
|
163
163
|
metadata: {}
|
164
|
-
post_install_message:
|
164
|
+
post_install_message:
|
165
165
|
rdoc_options: []
|
166
166
|
require_paths:
|
167
167
|
- lib
|
@@ -176,8 +176,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
176
176
|
- !ruby/object:Gem::Version
|
177
177
|
version: 2.5.0
|
178
178
|
requirements: []
|
179
|
-
rubygems_version: 3.1.
|
180
|
-
signing_key:
|
179
|
+
rubygems_version: 3.1.2
|
180
|
+
signing_key:
|
181
181
|
specification_version: 4
|
182
182
|
summary: Rust (Cargo) support for dependabot
|
183
183
|
test_files: []
|