dependabot-common 0.106.34 → 0.106.35
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e113808a578271526c147df4335fedb60cfeb19802f3f2e96f3bb09ee5d1f69a
|
4
|
+
data.tar.gz: 432aa7f481de6ec48e2ba29711bb41e6754075125ac83efcf31762761e19cdb6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 653fc36e4e76f30d2edd7e3d5998a4d8a041a77262a48fe55d30a4faad063abf808b117eb180fd9ad5500d78bfcbdc7f5380eab823d4b8d6ac86b0f9ed2c7ff1
|
7
|
+
data.tar.gz: 3e401c7ea85e6626d164536d3cb721dd4f9915c31c3a068d4ef9e419f557ea0467edeb341c09aeed9e8cf177a1708f71bab25cac63a3764be916e1320473205b
|
@@ -131,7 +131,7 @@ module Dependabot
|
|
131
131
|
retry_count += 1
|
132
132
|
raise if retry_count > 3
|
133
133
|
|
134
|
-
sleep(rand(
|
134
|
+
sleep(rand(1..1.99))
|
135
135
|
retry
|
136
136
|
end
|
137
137
|
end
|
@@ -172,26 +172,28 @@ module Dependabot
|
|
172
172
|
# A race condition may cause GitHub to fail here, in which case we retry
|
173
173
|
retry_count ||= 0
|
174
174
|
retry_count += 1
|
175
|
-
|
175
|
+
retry_count < 2 ? retry : raise
|
176
176
|
end
|
177
177
|
|
178
178
|
def create_branch(commit)
|
179
|
-
|
180
|
-
|
181
|
-
|
182
|
-
commit.sha
|
183
|
-
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
179
|
+
ref = "heads/#{branch_name}"
|
180
|
+
|
181
|
+
begin
|
182
|
+
github_client_for_source.create_ref(source.repo, ref, commit.sha)
|
183
|
+
rescue Octokit::UnprocessableEntity => e
|
184
|
+
# Return quietly in the case of a race
|
185
|
+
return nil if e.message.match?(/Reference already exists/i)
|
186
|
+
|
187
|
+
retrying_branch_creation ||= false
|
188
|
+
raise if retrying_branch_creation
|
188
189
|
|
189
|
-
|
190
|
+
retrying_branch_creation = true
|
190
191
|
|
191
|
-
|
192
|
-
|
193
|
-
|
194
|
-
|
192
|
+
# Branch creation will fail if a branch called `dependabot` already
|
193
|
+
# exists, since git won't be able to create a dir with the same name
|
194
|
+
ref = "heads/#{SecureRandom.hex[0..3] + branch_name}"
|
195
|
+
retry
|
196
|
+
end
|
195
197
|
end
|
196
198
|
|
197
199
|
def update_branch(commit)
|
data/lib/dependabot/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: dependabot-common
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.106.
|
4
|
+
version: 0.106.35
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dependabot
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-05-
|
11
|
+
date: 2019-05-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-ecr
|