dependabot-python 0.108.1 → 0.108.2
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/python/file_fetcher.rb +9 -3
- 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: 51d60d54ec3f354b29d3414f49081bf1fb490c12f7fa7170f925ac8dc22cce1b
|
|
4
|
+
data.tar.gz: 19919d89b53e0907780611e169d1f385bdf52933b2cfd647b43040b15a640d82
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: c0f02b5668db63ee597e8800781c463de18269ef2695bace65f56375cd34f78a34abf074d34d590e5eccd9883b2fd3d1b4e4dbff9d7c975f5dee8a11e729b3f4
|
|
7
|
+
data.tar.gz: 3ba1aa4853ec2e58e6b7d3ab4c91096be00bf6db58a9884bfed4552e9ad7aa50360a4b0ad258ca2c3c2fb913c1a8c08a3d77acf443dbe2695a2344fdd45483ea
|
|
@@ -12,7 +12,7 @@ module Dependabot
|
|
|
12
12
|
module Python
|
|
13
13
|
class FileFetcher < Dependabot::FileFetchers::Base
|
|
14
14
|
CHILD_REQUIREMENT_REGEX = /^-r\s?(?<path>.*\.(?:txt|in))/.freeze
|
|
15
|
-
CONSTRAINT_REGEX = /^-c\s?(?<path
|
|
15
|
+
CONSTRAINT_REGEX = /^-c\s?(?<path>.*\.(?:txt|in))/.freeze
|
|
16
16
|
|
|
17
17
|
def self.required_files_in?(filenames)
|
|
18
18
|
return true if filenames.any? { |name| name.end_with?(".txt", ".in") }
|
|
@@ -242,7 +242,13 @@ module Dependabot
|
|
|
242
242
|
child_requirement_txt_files
|
|
243
243
|
|
|
244
244
|
constraints_paths = all_requirement_files.map do |req_file|
|
|
245
|
-
req_file.
|
|
245
|
+
current_dir = File.dirname(req_file.name)
|
|
246
|
+
paths = req_file.content.scan(CONSTRAINT_REGEX).flatten
|
|
247
|
+
|
|
248
|
+
paths.map do |path|
|
|
249
|
+
path = File.join(current_dir, path) unless current_dir == "."
|
|
250
|
+
path = Pathname.new(path).cleanpath.to_path
|
|
251
|
+
end
|
|
246
252
|
end.flatten.uniq
|
|
247
253
|
|
|
248
254
|
constraints_paths.map { |path| fetch_file_from_host(path) }
|
|
@@ -319,7 +325,7 @@ module Dependabot
|
|
|
319
325
|
|
|
320
326
|
file.content.lines.all? do |line|
|
|
321
327
|
next true if line.strip.empty?
|
|
322
|
-
next true if line.start_with?("#", "-r ", "-c ", "-e ")
|
|
328
|
+
next true if line.start_with?("#", "-r ", "-c ", "-e ", "--")
|
|
323
329
|
|
|
324
330
|
line.match?(RequirementParser::VALID_REQ_TXT_REQUIREMENT)
|
|
325
331
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: dependabot-python
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.108.
|
|
4
|
+
version: 0.108.2
|
|
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.108.
|
|
19
|
+
version: 0.108.2
|
|
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.108.
|
|
26
|
+
version: 0.108.2
|
|
27
27
|
- !ruby/object:Gem::Dependency
|
|
28
28
|
name: byebug
|
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|