@aws-cdk/cloud-assembly-schema 54.2.0 → 54.4.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.
package/.jsii CHANGED
@@ -9,7 +9,7 @@
9
9
  },
10
10
  "bundled": {
11
11
  "jsonschema": "^1.5.0",
12
- "semver": "^7.8.1"
12
+ "semver": "^7.8.4"
13
13
  },
14
14
  "description": "Schema for the protocol between CDK framework and CDK CLI",
15
15
  "docs": {
@@ -7094,6 +7094,6 @@
7094
7094
  "symbolId": "lib/cloud-assembly/context-queries:VpcContextQuery"
7095
7095
  }
7096
7096
  },
7097
- "version": "54.2.0",
7097
+ "version": "54.4.0",
7098
7098
  "fingerprint": "**********"
7099
7099
  }
package/cli-version.json CHANGED
@@ -1 +1 @@
1
- {"version":"2.1126.0"}
1
+ {"version":"2.1128.0"}
package/lib/manifest.js CHANGED
@@ -267,7 +267,7 @@ class Manifest {
267
267
  }
268
268
  exports.Manifest = Manifest;
269
269
  _a = JSII_RTTI_SYMBOL_1;
270
- Manifest[_a] = { fqn: "@aws-cdk/cloud-assembly-schema.Manifest", version: "54.2.0" };
270
+ Manifest[_a] = { fqn: "@aws-cdk/cloud-assembly-schema.Manifest", version: "54.4.0" };
271
271
  function stripEnumErrors(errors) {
272
272
  return errors.filter((e) => typeof e.schema === 'string' || !('enum' in e.schema));
273
273
  }
@@ -277,6 +277,11 @@ const parseComparator = (comp, options) => {
277
277
 
278
278
  const isX = id => !id || id.toLowerCase() === 'x' || id === '*'
279
279
 
280
+ const invalidXRangeOrder = (M, m, p) => (
281
+ (isX(M) && !isX(m)) ||
282
+ (isX(m) && p && !isX(p))
283
+ )
284
+
280
285
  // ~, ~> --> * (any, kinda silly)
281
286
  // ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0-0
282
287
  // ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0-0
@@ -373,10 +378,10 @@ const replaceCaret = (comp, options) => {
373
378
  if (M === '0') {
374
379
  if (m === '0') {
375
380
  ret = `>=${M}.${m}.${p
376
- }${z} <${M}.${m}.${+p + 1}-0`
381
+ } <${M}.${m}.${+p + 1}-0`
377
382
  } else {
378
383
  ret = `>=${M}.${m}.${p
379
- }${z} <${M}.${+m + 1}.0-0`
384
+ } <${M}.${+m + 1}.0-0`
380
385
  }
381
386
  } else {
382
387
  ret = `>=${M}.${m}.${p
@@ -402,6 +407,10 @@ const replaceXRange = (comp, options) => {
402
407
  const r = options.loose ? re[t.XRANGELOOSE] : re[t.XRANGE]
403
408
  return comp.replace(r, (ret, gtlt, M, m, p, pr) => {
404
409
  debug('xRange', comp, ret, gtlt, M, m, p, pr)
410
+ if (invalidXRangeOrder(M, m, p)) {
411
+ return comp
412
+ }
413
+
405
414
  const xM = isX(M)
406
415
  const xm = xM || isX(m)
407
416
  const xp = xm || isX(p)
@@ -6,6 +6,22 @@ const { safeRe: re, t } = require('../internal/re')
6
6
 
7
7
  const parseOptions = require('../internal/parse-options')
8
8
  const { compareIdentifiers } = require('../internal/identifiers')
9
+
10
+ const isPrereleaseIdentifier = (prerelease, identifier) => {
11
+ const identifiers = identifier.split('.')
12
+ if (identifiers.length > prerelease.length) {
13
+ return false
14
+ }
15
+
16
+ for (let i = 0; i < identifiers.length; i++) {
17
+ if (compareIdentifiers(prerelease[i], identifiers[i]) !== 0) {
18
+ return false
19
+ }
20
+ }
21
+
22
+ return true
23
+ }
24
+
9
25
  class SemVer {
10
26
  constructor (version, options) {
11
27
  options = parseOptions(options)
@@ -309,8 +325,9 @@ class SemVer {
309
325
  if (identifierBase === false) {
310
326
  prerelease = [identifier]
311
327
  }
312
- if (compareIdentifiers(this.prerelease[0], identifier) === 0) {
313
- if (isNaN(this.prerelease[1])) {
328
+ if (isPrereleaseIdentifier(this.prerelease, identifier)) {
329
+ const prereleaseBase = this.prerelease[identifier.split('.').length]
330
+ if (isNaN(prereleaseBase)) {
314
331
  this.prerelease = prerelease
315
332
  }
316
333
  } else {
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "semver",
3
- "version": "7.8.1",
3
+ "version": "7.8.4",
4
4
  "description": "The semantic version parser used by npm.",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -14,7 +14,7 @@
14
14
  "eslint": "eslint \"**/*.{js,cjs,ts,mjs,jsx,tsx}\""
15
15
  },
16
16
  "devDependencies": {
17
- "@npmcli/eslint-config": "^6.0.0",
17
+ "@npmcli/eslint-config": "^7.0.0",
18
18
  "@npmcli/template-oss": "5.0.0",
19
19
  "benchmark": "^2.1.4",
20
20
  "tap": "^16.0.0"
package/package.json CHANGED
@@ -39,19 +39,19 @@
39
39
  "organization": true
40
40
  },
41
41
  "devDependencies": {
42
- "@cdklabs/eslint-plugin": "^2.0.7",
42
+ "@cdklabs/eslint-plugin": "^2.0.9",
43
43
  "@stylistic/eslint-plugin": "^3",
44
44
  "@types/jest": "^29.5.14",
45
45
  "@types/node": "^20",
46
46
  "@types/semver": "^7.7.1",
47
47
  "@typescript-eslint/eslint-plugin": "^8",
48
48
  "@typescript-eslint/parser": "^8",
49
- "cdk-generate-synthetic-examples": "^0.2.50",
49
+ "cdk-generate-synthetic-examples": "^0.2.51",
50
50
  "commit-and-tag-version": "^12",
51
51
  "constructs": "^10.0.0",
52
52
  "eslint": "^9",
53
53
  "eslint-config-prettier": "^10.1.8",
54
- "eslint-import-resolver-typescript": "^4.4.4",
54
+ "eslint-import-resolver-typescript": "^4.4.5",
55
55
  "eslint-plugin-import": "^2.32.0",
56
56
  "eslint-plugin-jest": "^29.15.2",
57
57
  "eslint-plugin-jsdoc": "^62.9.0",
@@ -59,14 +59,14 @@
59
59
  "jest": "^29.7.0",
60
60
  "jest-junit": "^16",
61
61
  "jsii": "5.9",
62
- "jsii-diff": "^1.132.0",
63
- "jsii-pacmak": "^1.132.0",
62
+ "jsii-diff": "^1.135.0",
63
+ "jsii-pacmak": "^1.135.0",
64
64
  "jsii-rosetta": "5.9",
65
65
  "license-checker": "^25.0.1",
66
66
  "mock-fs": "^5.5.0",
67
67
  "nx": "^22.7.5",
68
68
  "prettier": "^2.8",
69
- "projen": "^0.99.70",
69
+ "projen": "^0.99.73",
70
70
  "ts-jest": "^29.4.11",
71
71
  "tsx": "^4.22.4",
72
72
  "typescript": "5.9",
@@ -74,7 +74,7 @@
74
74
  },
75
75
  "dependencies": {
76
76
  "jsonschema": "^1.5.0",
77
- "semver": "^7.8.1"
77
+ "semver": "^7.8.4"
78
78
  },
79
79
  "bundledDependencies": [
80
80
  "jsonschema",
@@ -100,7 +100,7 @@
100
100
  "publishConfig": {
101
101
  "access": "public"
102
102
  },
103
- "version": "54.2.0",
103
+ "version": "54.4.0",
104
104
  "packageManager": "yarn@4.13.0",
105
105
  "types": "lib/index.d.ts",
106
106
  "stability": "stable",