dependabot-npm_and_yarn 0.153.0 → 0.154.4

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: 4e2777bfb9c1f62ee544293d44f304e5035ca22248cef99844b43d7a39aeacef
4
- data.tar.gz: 34e23f42bfde5035c268f00c71ba3ae9bad6237aa6ed3389d1a204b0dda031db
3
+ metadata.gz: ee906342bdb5d0aefcf1787a905edc4695599d1b0ae6b6a107b262f9c10804d2
4
+ data.tar.gz: 1cbce2f27ef4ad2bad6ac330b6a76d7d587bcb292014d6700108142143fe654b
5
5
  SHA512:
6
- metadata.gz: 3bc217b4e1207054ec67a376a878328c91499f010fc0faa90ddae72e0a537cdaf98df1bf0096eb3dbbcdf3e2076363eb58d80e14cfd64f731430df62c447cd54
7
- data.tar.gz: aee4de95e19f880537816108df9a535d97dcec816db8091f841fa9f8be717e78f9c3951a218b3031191eefd9aaaaea7addbb70f3e5885d054d516790217d420e
6
+ metadata.gz: c7cd1fd9841cecc6001e138b52349e242cb8471fe7ddfb2eb3b8ae070ba456646e549bca5c0a7ffe328431a988023cf36cd823abec0696ee6fe59d0a3800a487
7
+ data.tar.gz: 84b1ddbc2c096cac50491289492421ea18feb60d23422325e211b9d8307ad0b09d12040989c91e6d36e9207ef6bf7ec467487c95840362678aea157c920ab6d6
@@ -7,7 +7,7 @@
7
7
  "name": "@dependabot/helper",
8
8
  "dependencies": {
9
9
  "@dependabot/yarn-lib": "^1.21.1",
10
- "@npmcli/arborist": "^2.6.2",
10
+ "@npmcli/arborist": "^2.6.3",
11
11
  "detect-indent": "^6.1.0",
12
12
  "npm": "6.14.13",
13
13
  "semver": "^7.3.4"
@@ -16,7 +16,7 @@
16
16
  "helper": "run.js"
17
17
  },
18
18
  "devDependencies": {
19
- "eslint": "^7.28.0",
19
+ "eslint": "^7.29.0",
20
20
  "eslint-config-prettier": "^8.3.0",
21
21
  "jest": "^27.0.4",
22
22
  "prettier": "^2.3.1",
@@ -1430,9 +1430,9 @@
1430
1430
  }
1431
1431
  },
1432
1432
  "node_modules/@npmcli/arborist": {
1433
- "version": "2.6.2",
1434
- "resolved": "https://registry.npmjs.org/@npmcli/arborist/-/arborist-2.6.2.tgz",
1435
- "integrity": "sha512-CAo0HSziRdlpGUUheERmOrADnKHfBYpLAl/HmWGwGCtWKB3BCxfgb0rJ7MsFg38wy7YF3+fDs7R9dMVCH89K/A==",
1433
+ "version": "2.6.3",
1434
+ "resolved": "https://registry.npmjs.org/@npmcli/arborist/-/arborist-2.6.3.tgz",
1435
+ "integrity": "sha512-R8U2dZ8+jeE7go+qNU4Mt6aiXyBu3mM75iRIugNCA4P0OWlsLOpuDPPhsaRcOVbtXheOGZXrqe36qP1g+M68KQ==",
1436
1436
  "dependencies": {
1437
1437
  "@npmcli/installed-package-contents": "^1.0.7",
1438
1438
  "@npmcli/map-workspaces": "^1.0.2",
@@ -1453,6 +1453,7 @@
1453
1453
  "npm-registry-fetch": "^11.0.0",
1454
1454
  "pacote": "^11.2.6",
1455
1455
  "parse-conflict-json": "^1.1.1",
1456
+ "proc-log": "^1.0.0",
1456
1457
  "promise-all-reject-late": "^1.0.0",
1457
1458
  "promise-call-limit": "^1.0.1",
1458
1459
  "read-package-json-fast": "^2.0.2",
@@ -3260,9 +3261,9 @@
3260
3261
  }
3261
3262
  },
3262
3263
  "node_modules/eslint": {
3263
- "version": "7.28.0",
3264
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-7.28.0.tgz",
3265
- "integrity": "sha512-UMfH0VSjP0G4p3EWirscJEQ/cHqnT/iuH6oNZOB94nBjWbMnhGEPxsZm1eyIW0C/9jLI0Fow4W5DXLjEI7mn1g==",
3264
+ "version": "7.29.0",
3265
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-7.29.0.tgz",
3266
+ "integrity": "sha512-82G/JToB9qIy/ArBzIWG9xvvwL3R86AlCjtGw+A29OMZDqhTybz/MByORSukGxeI+YPCR4coYyITKk8BFH9nDA==",
3266
3267
  "dev": true,
3267
3268
  "dependencies": {
3268
3269
  "@babel/code-frame": "7.12.11",
@@ -12553,6 +12554,11 @@
12553
12554
  "url": "https://github.com/chalk/ansi-styles?sponsor=1"
12554
12555
  }
12555
12556
  },
12557
+ "node_modules/proc-log": {
12558
+ "version": "1.0.0",
12559
+ "resolved": "https://registry.npmjs.org/proc-log/-/proc-log-1.0.0.tgz",
12560
+ "integrity": "sha512-aCk8AO51s+4JyuYGg3Q/a6gnrlDO09NpVWePtjp7xwphcoQ04x5WAfCyugcsbLooWcMJ87CLkD4+604IckEdhg=="
12561
+ },
12556
12562
  "node_modules/process-nextick-args": {
12557
12563
  "version": "2.0.1",
12558
12564
  "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz",
@@ -15480,9 +15486,9 @@
15480
15486
  }
15481
15487
  },
15482
15488
  "@npmcli/arborist": {
15483
- "version": "2.6.2",
15484
- "resolved": "https://registry.npmjs.org/@npmcli/arborist/-/arborist-2.6.2.tgz",
15485
- "integrity": "sha512-CAo0HSziRdlpGUUheERmOrADnKHfBYpLAl/HmWGwGCtWKB3BCxfgb0rJ7MsFg38wy7YF3+fDs7R9dMVCH89K/A==",
15489
+ "version": "2.6.3",
15490
+ "resolved": "https://registry.npmjs.org/@npmcli/arborist/-/arborist-2.6.3.tgz",
15491
+ "integrity": "sha512-R8U2dZ8+jeE7go+qNU4Mt6aiXyBu3mM75iRIugNCA4P0OWlsLOpuDPPhsaRcOVbtXheOGZXrqe36qP1g+M68KQ==",
15486
15492
  "requires": {
15487
15493
  "@npmcli/installed-package-contents": "^1.0.7",
15488
15494
  "@npmcli/map-workspaces": "^1.0.2",
@@ -15503,6 +15509,7 @@
15503
15509
  "npm-registry-fetch": "^11.0.0",
15504
15510
  "pacote": "^11.2.6",
15505
15511
  "parse-conflict-json": "^1.1.1",
15512
+ "proc-log": "^1.0.0",
15506
15513
  "promise-all-reject-late": "^1.0.0",
15507
15514
  "promise-call-limit": "^1.0.1",
15508
15515
  "read-package-json-fast": "^2.0.2",
@@ -16970,9 +16977,9 @@
16970
16977
  }
16971
16978
  },
16972
16979
  "eslint": {
16973
- "version": "7.28.0",
16974
- "resolved": "https://registry.npmjs.org/eslint/-/eslint-7.28.0.tgz",
16975
- "integrity": "sha512-UMfH0VSjP0G4p3EWirscJEQ/cHqnT/iuH6oNZOB94nBjWbMnhGEPxsZm1eyIW0C/9jLI0Fow4W5DXLjEI7mn1g==",
16980
+ "version": "7.29.0",
16981
+ "resolved": "https://registry.npmjs.org/eslint/-/eslint-7.29.0.tgz",
16982
+ "integrity": "sha512-82G/JToB9qIy/ArBzIWG9xvvwL3R86AlCjtGw+A29OMZDqhTybz/MByORSukGxeI+YPCR4coYyITKk8BFH9nDA==",
16976
16983
  "dev": true,
16977
16984
  "requires": {
16978
16985
  "@babel/code-frame": "7.12.11",
@@ -23759,6 +23766,11 @@
23759
23766
  }
23760
23767
  }
23761
23768
  },
23769
+ "proc-log": {
23770
+ "version": "1.0.0",
23771
+ "resolved": "https://registry.npmjs.org/proc-log/-/proc-log-1.0.0.tgz",
23772
+ "integrity": "sha512-aCk8AO51s+4JyuYGg3Q/a6gnrlDO09NpVWePtjp7xwphcoQ04x5WAfCyugcsbLooWcMJ87CLkD4+604IckEdhg=="
23773
+ },
23762
23774
  "process-nextick-args": {
23763
23775
  "version": "2.0.1",
23764
23776
  "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz",
data/helpers/package.json CHANGED
@@ -10,13 +10,13 @@
10
10
  },
11
11
  "dependencies": {
12
12
  "@dependabot/yarn-lib": "^1.21.1",
13
- "@npmcli/arborist": "^2.6.2",
13
+ "@npmcli/arborist": "^2.6.3",
14
14
  "detect-indent": "^6.1.0",
15
15
  "npm": "6.14.13",
16
16
  "semver": "^7.3.4"
17
17
  },
18
18
  "devDependencies": {
19
- "eslint": "^7.28.0",
19
+ "eslint": "^7.29.0",
20
20
  "eslint-config-prettier": "^8.3.0",
21
21
  "jest": "^27.0.4",
22
22
  "prettier": "^2.3.1",
@@ -170,7 +170,7 @@ module Dependabot
170
170
  [{ production: !details["dev"] }]
171
171
  end
172
172
 
173
- dependency_set << Dependency.new(dependency_args)
173
+ dependency_set << Dependency.new(**dependency_args)
174
174
  dependency_set += recursively_fetch_npm_lock_dependencies(details)
175
175
  end
176
176
 
@@ -2,6 +2,7 @@
2
2
 
3
3
  require "excon"
4
4
  require "dependabot/npm_and_yarn/update_checker"
5
+ require "dependabot/update_checkers/version_filters"
5
6
  require "dependabot/npm_and_yarn/update_checker/registry_finder"
6
7
  require "dependabot/npm_and_yarn/version"
7
8
  require "dependabot/npm_and_yarn/requirement"
@@ -58,15 +59,17 @@ module Dependabot
58
59
  def lowest_security_fix_version
59
60
  return unless valid_npm_details?
60
61
 
61
- versions_array =
62
+ secure_versions =
62
63
  if specified_dist_tag_requirement?
63
64
  [version_from_dist_tags].compact
64
65
  else possible_versions(filter_ignored: false)
65
66
  end
66
67
 
67
- secure_versions = filter_vulnerable_versions(versions_array)
68
+ secure_versions = Dependabot::UpdateCheckers::VersionFilters.filter_vulnerable_versions(secure_versions,
69
+ security_advisories)
68
70
  secure_versions = filter_ignored_versions(secure_versions)
69
71
  secure_versions = filter_lower_versions(secure_versions)
72
+
70
73
  secure_versions.reverse.find { |version| !yanked?(version) }
71
74
  rescue Excon::Error::Socket, Excon::Error::Timeout
72
75
  raise if dependency_registry == "registry.npmjs.org"
@@ -125,18 +128,6 @@ module Dependabot
125
128
  select { |v| reqs.all? { |r| r.any? { |o| o.satisfied_by?(v) } } }
126
129
  end
127
130
 
128
- def filter_vulnerable_versions(versions_array)
129
- updated_versions_array = versions_array
130
-
131
- security_advisories.each do |advisory|
132
- updated_versions_array =
133
- updated_versions_array.
134
- reject { |v| advisory.vulnerable?(v) }
135
- end
136
-
137
- updated_versions_array
138
- end
139
-
140
131
  def filter_lower_versions(versions_array)
141
132
  return versions_array unless dependency.version && version_class.correct?(dependency.version)
142
133
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dependabot-npm_and_yarn
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.153.0
4
+ version: 0.154.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dependabot
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-06-14 00:00:00.000000000 Z
11
+ date: 2021-06-22 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.153.0
19
+ version: 0.154.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.153.0
26
+ version: 0.154.4
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: byebug
29
29
  requirement: !ruby/object:Gem::Requirement