dependabot-common 0.286.0 → 0.287.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/pull_request_creator/github.rb +12 -7
- data/lib/dependabot.rb +1 -1
- 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: 29a554da8bfe1c29b45541c68eb5c311d1631785725e63d84d9a6d6952324c39
|
|
4
|
+
data.tar.gz: 6aece2522be172f7bc1cb521210121fbe66a21509c9181239b6ed6166df41735
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8a5c341db6ff520a170163ab9886c897be6f33f144451d7f79fa2f4adddb44038a8eb616320e39e28bc4306d86222e20f9337125c8adb7577c3acfc085fb7802
|
|
7
|
+
data.tar.gz: 55187173f82cea30b99fbc01418d44ea2b570ef7d88db7a15a85950c00dbe7798c66163d4530a6c053c60fb65e32e2c0f317f090fcf589211d7d31371621d0be
|
|
@@ -114,15 +114,15 @@ module Dependabot
|
|
|
114
114
|
"Initiating Github pull request."
|
|
115
115
|
)
|
|
116
116
|
|
|
117
|
-
if experiment_duplicate_branch? && branch_exists?(branch_name)
|
|
117
|
+
if experiment_duplicate_branch? && branch_exists?(branch_name) && no_pull_request_exists?
|
|
118
118
|
Dependabot.logger.info(
|
|
119
119
|
"Existing branch \"#{branch_name}\" found. Pull request not created."
|
|
120
120
|
)
|
|
121
121
|
raise BranchAlreadyExists, "Duplicate branch #{branch_name} already exists"
|
|
122
122
|
end
|
|
123
123
|
|
|
124
|
-
if branch_exists?(branch_name) &&
|
|
125
|
-
raise UnmergedPRExists, "PR ##{
|
|
124
|
+
if branch_exists?(branch_name) && open_pull_request_exists?
|
|
125
|
+
raise UnmergedPRExists, "PR ##{open_pull_requests.first.number} already exists"
|
|
126
126
|
end
|
|
127
127
|
if require_up_to_date_base? && !base_commit_is_up_to_date?
|
|
128
128
|
raise BaseCommitNotUpToDate, "HEAD #{head_commit} does not match base #{base_commit}"
|
|
@@ -164,13 +164,18 @@ module Dependabot
|
|
|
164
164
|
# rubocop:enable Metrics/PerceivedComplexity
|
|
165
165
|
|
|
166
166
|
sig { returns(T::Boolean) }
|
|
167
|
-
def
|
|
168
|
-
|
|
167
|
+
def no_pull_request_exists?
|
|
168
|
+
pull_requests_for_branch.none?
|
|
169
|
+
end
|
|
170
|
+
|
|
171
|
+
sig { returns(T::Boolean) }
|
|
172
|
+
def open_pull_request_exists?
|
|
173
|
+
open_pull_requests.any?
|
|
169
174
|
end
|
|
170
175
|
|
|
171
176
|
sig { returns(T::Array[T.untyped]) }
|
|
172
|
-
def
|
|
173
|
-
pull_requests_for_branch.reject(&:merged)
|
|
177
|
+
def open_pull_requests
|
|
178
|
+
pull_requests_for_branch.reject(&:closed).reject(&:merged)
|
|
174
179
|
end
|
|
175
180
|
|
|
176
181
|
sig { returns(T::Array[T.untyped]) }
|
data/lib/dependabot.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.
|
|
4
|
+
version: 0.287.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Dependabot
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2024-11-
|
|
11
|
+
date: 2024-11-19 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: aws-sdk-codecommit
|
|
@@ -614,7 +614,7 @@ licenses:
|
|
|
614
614
|
- MIT
|
|
615
615
|
metadata:
|
|
616
616
|
bug_tracker_uri: https://github.com/dependabot/dependabot-core/issues
|
|
617
|
-
changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.
|
|
617
|
+
changelog_uri: https://github.com/dependabot/dependabot-core/releases/tag/v0.287.0
|
|
618
618
|
post_install_message:
|
|
619
619
|
rdoc_options: []
|
|
620
620
|
require_paths:
|