cdk-common 2.0.826 → 2.0.828

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.
Files changed (91) hide show
  1. package/.jsii +2 -2
  2. package/lib/main.js +1 -1
  3. package/node_modules/table/node_modules/ajv/README.md +1 -1
  4. package/node_modules/table/node_modules/ajv/dist/2019.d.ts +1 -1
  5. package/node_modules/table/node_modules/ajv/dist/2019.js +3 -1
  6. package/node_modules/table/node_modules/ajv/dist/2019.js.map +1 -1
  7. package/node_modules/table/node_modules/ajv/dist/2020.d.ts +1 -1
  8. package/node_modules/table/node_modules/ajv/dist/2020.js +3 -1
  9. package/node_modules/table/node_modules/ajv/dist/2020.js.map +1 -1
  10. package/node_modules/table/node_modules/ajv/dist/ajv.d.ts +1 -1
  11. package/node_modules/table/node_modules/ajv/dist/ajv.js +3 -1
  12. package/node_modules/table/node_modules/ajv/dist/ajv.js.map +1 -1
  13. package/node_modules/table/node_modules/ajv/dist/compile/codegen/code.js.map +1 -1
  14. package/node_modules/table/node_modules/ajv/dist/compile/codegen/index.js.map +1 -1
  15. package/node_modules/table/node_modules/ajv/dist/compile/codegen/scope.js +1 -1
  16. package/node_modules/table/node_modules/ajv/dist/compile/codegen/scope.js.map +1 -1
  17. package/node_modules/table/node_modules/ajv/dist/compile/errors.js +1 -1
  18. package/node_modules/table/node_modules/ajv/dist/compile/errors.js.map +1 -1
  19. package/node_modules/table/node_modules/ajv/dist/compile/index.js +1 -1
  20. package/node_modules/table/node_modules/ajv/dist/compile/index.js.map +1 -1
  21. package/node_modules/table/node_modules/ajv/dist/compile/jtd/parse.js.map +1 -1
  22. package/node_modules/table/node_modules/ajv/dist/compile/jtd/serialize.js.map +1 -1
  23. package/node_modules/table/node_modules/ajv/dist/compile/jtd/types.d.ts +1 -1
  24. package/node_modules/table/node_modules/ajv/dist/compile/names.js +6 -6
  25. package/node_modules/table/node_modules/ajv/dist/compile/names.js.map +1 -1
  26. package/node_modules/table/node_modules/ajv/dist/compile/resolve.js +4 -4
  27. package/node_modules/table/node_modules/ajv/dist/compile/resolve.js.map +1 -1
  28. package/node_modules/table/node_modules/ajv/dist/compile/rules.d.ts +1 -1
  29. package/node_modules/table/node_modules/ajv/dist/compile/util.js +1 -1
  30. package/node_modules/table/node_modules/ajv/dist/compile/util.js.map +1 -1
  31. package/node_modules/table/node_modules/ajv/dist/compile/validate/boolSchema.js.map +1 -1
  32. package/node_modules/table/node_modules/ajv/dist/compile/validate/dataType.js +2 -1
  33. package/node_modules/table/node_modules/ajv/dist/compile/validate/dataType.js.map +1 -1
  34. package/node_modules/table/node_modules/ajv/dist/compile/validate/defaults.js.map +1 -1
  35. package/node_modules/table/node_modules/ajv/dist/compile/validate/index.js.map +1 -1
  36. package/node_modules/table/node_modules/ajv/dist/compile/validate/keyword.js.map +1 -1
  37. package/node_modules/table/node_modules/ajv/dist/compile/validate/subschema.js.map +1 -1
  38. package/node_modules/table/node_modules/ajv/dist/core.js +2 -1
  39. package/node_modules/table/node_modules/ajv/dist/core.js.map +1 -1
  40. package/node_modules/table/node_modules/ajv/dist/jtd.d.ts +1 -1
  41. package/node_modules/table/node_modules/ajv/dist/jtd.js +3 -1
  42. package/node_modules/table/node_modules/ajv/dist/jtd.js.map +1 -1
  43. package/node_modules/table/node_modules/ajv/dist/runtime/parseJson.js +2 -1
  44. package/node_modules/table/node_modules/ajv/dist/runtime/parseJson.js.map +1 -1
  45. package/node_modules/table/node_modules/ajv/dist/runtime/ucs2length.js.map +1 -1
  46. package/node_modules/table/node_modules/ajv/dist/standalone/index.js.map +1 -1
  47. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/additionalItems.js.map +1 -1
  48. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/additionalProperties.js.map +1 -1
  49. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/contains.js.map +1 -1
  50. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/dependencies.js.map +1 -1
  51. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/if.js.map +1 -1
  52. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/items.js.map +1 -1
  53. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/not.js.map +1 -1
  54. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/oneOf.js.map +1 -1
  55. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/patternProperties.js.map +1 -1
  56. package/node_modules/table/node_modules/ajv/dist/vocabularies/applicator/properties.js.map +1 -1
  57. package/node_modules/table/node_modules/ajv/dist/vocabularies/code.js.map +1 -1
  58. package/node_modules/table/node_modules/ajv/dist/vocabularies/core/ref.js.map +1 -1
  59. package/node_modules/table/node_modules/ajv/dist/vocabularies/discriminator/index.js.map +1 -1
  60. package/node_modules/table/node_modules/ajv/dist/vocabularies/discriminator/types.js +1 -1
  61. package/node_modules/table/node_modules/ajv/dist/vocabularies/discriminator/types.js.map +1 -1
  62. package/node_modules/table/node_modules/ajv/dist/vocabularies/dynamic/dynamicRef.js.map +1 -1
  63. package/node_modules/table/node_modules/ajv/dist/vocabularies/format/format.js.map +1 -1
  64. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/discriminator.js.map +1 -1
  65. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/enum.js.map +1 -1
  66. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/metadata.js.map +1 -1
  67. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/nullable.js.map +1 -1
  68. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/properties.js.map +1 -1
  69. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/ref.js.map +1 -1
  70. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/type.js.map +1 -1
  71. package/node_modules/table/node_modules/ajv/dist/vocabularies/jtd/values.js.map +1 -1
  72. package/node_modules/table/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedItems.js.map +1 -1
  73. package/node_modules/table/node_modules/ajv/dist/vocabularies/unevaluated/unevaluatedProperties.js.map +1 -1
  74. package/node_modules/table/node_modules/ajv/dist/vocabularies/validation/const.js.map +1 -1
  75. package/node_modules/table/node_modules/ajv/dist/vocabularies/validation/enum.js.map +1 -1
  76. package/node_modules/table/node_modules/ajv/dist/vocabularies/validation/limitContains.js.map +1 -1
  77. package/node_modules/table/node_modules/ajv/dist/vocabularies/validation/required.js.map +1 -1
  78. package/node_modules/table/node_modules/ajv/lib/2019.ts +2 -1
  79. package/node_modules/table/node_modules/ajv/lib/2020.ts +2 -1
  80. package/node_modules/table/node_modules/ajv/lib/ajv.ts +2 -1
  81. package/node_modules/table/node_modules/ajv/lib/compile/codegen/index.ts +25 -5
  82. package/node_modules/table/node_modules/ajv/lib/compile/jtd/types.ts +1 -1
  83. package/node_modules/table/node_modules/ajv/lib/compile/resolve.ts +4 -4
  84. package/node_modules/table/node_modules/ajv/lib/compile/rules.ts +1 -1
  85. package/node_modules/table/node_modules/ajv/lib/compile/validate/dataType.ts +1 -0
  86. package/node_modules/table/node_modules/ajv/lib/core.ts +4 -0
  87. package/node_modules/table/node_modules/ajv/lib/jtd.ts +2 -1
  88. package/node_modules/table/node_modules/ajv/lib/runtime/parseJson.ts +2 -1
  89. package/node_modules/table/node_modules/ajv/lib/types/index.ts +7 -3
  90. package/node_modules/table/node_modules/ajv/package.json +40 -40
  91. package/package.json +2 -2
@@ -41,7 +41,11 @@ abstract class Node {
41
41
  }
42
42
 
43
43
  class Def extends Node {
44
- constructor(private readonly varKind: Name, private readonly name: Name, private rhs?: SafeExpr) {
44
+ constructor(
45
+ private readonly varKind: Name,
46
+ private readonly name: Name,
47
+ private rhs?: SafeExpr
48
+ ) {
45
49
  super()
46
50
  }
47
51
 
@@ -63,7 +67,11 @@ class Def extends Node {
63
67
  }
64
68
 
65
69
  class Assign extends Node {
66
- constructor(readonly lhs: Code, public rhs: SafeExpr, private readonly sideEffects?: boolean) {
70
+ constructor(
71
+ readonly lhs: Code,
72
+ public rhs: SafeExpr,
73
+ private readonly sideEffects?: boolean
74
+ ) {
67
75
  super()
68
76
  }
69
77
 
@@ -84,7 +92,12 @@ class Assign extends Node {
84
92
  }
85
93
 
86
94
  class AssignOp extends Assign {
87
- constructor(lhs: Code, private readonly op: Code, rhs: SafeExpr, sideEffects?: boolean) {
95
+ constructor(
96
+ lhs: Code,
97
+ private readonly op: Code,
98
+ rhs: SafeExpr,
99
+ sideEffects?: boolean
100
+ ) {
88
101
  super(lhs, rhs, sideEffects)
89
102
  }
90
103
 
@@ -211,7 +224,10 @@ class Else extends BlockNode {
211
224
  class If extends BlockNode {
212
225
  static readonly kind = "if"
213
226
  else?: If | Else
214
- constructor(private condition: Code | boolean, nodes?: ChildNode[]) {
227
+ constructor(
228
+ private condition: Code | boolean,
229
+ nodes?: ChildNode[]
230
+ ) {
215
231
  super(nodes)
216
232
  }
217
233
 
@@ -331,7 +347,11 @@ class ForIter extends For {
331
347
 
332
348
  class Func extends BlockNode {
333
349
  static readonly kind = "func"
334
- constructor(public name: Name, public args: Code, public async?: boolean) {
350
+ constructor(
351
+ public name: Name,
352
+ public args: Code,
353
+ public async?: boolean
354
+ ) {
335
355
  super()
336
356
  }
337
357
 
@@ -13,4 +13,4 @@ export const jtdForms = [
13
13
  "ref",
14
14
  ] as const
15
15
 
16
- export type JTDForm = typeof jtdForms[number]
16
+ export type JTDForm = (typeof jtdForms)[number]
@@ -102,16 +102,16 @@ export function getSchemaRefs(this: Ajv, schema: AnySchema, baseId: string): Loc
102
102
  traverse(schema, {allKeys: true}, (sch, jsonPtr, _, parentJsonPtr) => {
103
103
  if (parentJsonPtr === undefined) return
104
104
  const fullPath = pathPrefix + jsonPtr
105
- let baseId = baseIds[parentJsonPtr]
106
- if (typeof sch[schemaId] == "string") baseId = addRef.call(this, sch[schemaId])
105
+ let innerBaseId = baseIds[parentJsonPtr]
106
+ if (typeof sch[schemaId] == "string") innerBaseId = addRef.call(this, sch[schemaId])
107
107
  addAnchor.call(this, sch.$anchor)
108
108
  addAnchor.call(this, sch.$dynamicAnchor)
109
- baseIds[jsonPtr] = baseId
109
+ baseIds[jsonPtr] = innerBaseId
110
110
 
111
111
  function addRef(this: Ajv, ref: string): string {
112
112
  // eslint-disable-next-line @typescript-eslint/unbound-method
113
113
  const _resolve = this.opts.uriResolver.resolve
114
- ref = normalizeId(baseId ? _resolve(baseId, ref) : ref)
114
+ ref = normalizeId(innerBaseId ? _resolve(innerBaseId, ref) : ref)
115
115
  if (schemaRefs.has(ref)) throw ambiguos(ref)
116
116
  schemaRefs.add(ref)
117
117
  let schOrRef = this.refs[ref]
@@ -2,7 +2,7 @@ import type {AddedKeywordDefinition} from "../types"
2
2
 
3
3
  const _jsonTypes = ["string", "number", "integer", "boolean", "null", "object", "array"] as const
4
4
 
5
- export type JSONType = typeof _jsonTypes[number]
5
+ export type JSONType = (typeof _jsonTypes)[number]
6
6
 
7
7
  const jsonTypes: Set<string> = new Set(_jsonTypes)
8
8
 
@@ -30,6 +30,7 @@ export function getSchemaTypes(schema: AnySchemaObject): JSONType[] {
30
30
  return types
31
31
  }
32
32
 
33
+ // eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
33
34
  export function getJSONTypes(ts: unknown | unknown[]): JSONType[] {
34
35
  const types: unknown[] = Array.isArray(ts) ? ts : ts ? [ts] : []
35
36
  if (types.every(isJSONType)) return types
@@ -343,14 +343,17 @@ export default class Ajv {
343
343
  validate<T>(schema: JTDSchemaType<T>, data: unknown): data is T
344
344
  // This overload is only intended for typescript inference, the first
345
345
  // argument prevents manual type annotation from matching this overload
346
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
346
347
  validate<N extends never, T extends SomeJTDSchemaType>(
347
348
  schema: T,
348
349
  data: unknown
349
350
  ): data is JTDDataType<T>
351
+ // eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
350
352
  validate<T>(schema: AsyncSchema, data: unknown | T): Promise<T>
351
353
  validate<T>(schemaKeyRef: AnySchema | string, data: unknown): data is T | Promise<T>
352
354
  validate<T>(
353
355
  schemaKeyRef: AnySchema | string, // key, ref or schema object
356
+ // eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
354
357
  data: unknown | T // to be validated
355
358
  ): boolean | Promise<T> {
356
359
  let v: AnyValidateFunction | undefined
@@ -374,6 +377,7 @@ export default class Ajv {
374
377
  compile<T = unknown>(schema: JTDSchemaType<T>, _meta?: boolean): ValidateFunction<T>
375
378
  // This overload is only intended for typescript inference, the first
376
379
  // argument prevents manual type annotation from matching this overload
380
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
377
381
  compile<N extends never, T extends SomeJTDSchemaType>(
378
382
  schema: T,
379
383
  _meta?: boolean
@@ -35,7 +35,7 @@ type JTDOptions = CurrentOptions & {
35
35
  multipleOfPrecision?: never
36
36
  }
37
37
 
38
- class Ajv extends AjvCore {
38
+ export class Ajv extends AjvCore {
39
39
  constructor(opts: JTDOptions = {}) {
40
40
  super({
41
41
  ...opts,
@@ -93,6 +93,7 @@ class Ajv extends AjvCore {
93
93
  }
94
94
 
95
95
  module.exports = exports = Ajv
96
+ module.exports.Ajv = Ajv
96
97
  Object.defineProperty(exports, "__esModule", {value: true})
97
98
 
98
99
  export default Ajv
@@ -1,4 +1,4 @@
1
- const rxParseJson = /position\s(\d+)$/
1
+ const rxParseJson = /position\s(\d+)(?: \(line \d+ column \d+\))?$/
2
2
 
3
3
  export function parseJson(s: string, pos: number): unknown {
4
4
  let endPos: number | undefined
@@ -129,6 +129,7 @@ export function parseJsonString(s: string, pos: number): string | undefined {
129
129
  while (count--) {
130
130
  code <<= 4
131
131
  c = s[pos]
132
+ // eslint-disable-next-line @typescript-eslint/no-unnecessary-condition
132
133
  if (c === undefined) {
133
134
  errorMessage("unexpected end")
134
135
  return undefined
@@ -48,6 +48,7 @@ export interface DataValidationCxt<T extends string | number = string | number>
48
48
  }
49
49
 
50
50
  export interface ValidateFunction<T = unknown> {
51
+ // eslint-disable-next-line @typescript-eslint/no-redundant-type-constituents
51
52
  (this: Ajv | any, data: any, dataCxt?: DataValidationCxt): data is T
52
53
  errors?: null | ErrorObject[]
53
54
  evaluated?: Evaluated
@@ -138,9 +139,12 @@ export interface DataValidateFunction {
138
139
  }
139
140
 
140
141
  export interface SchemaValidateFunction {
141
- (schema: any, data: any, parentSchema?: AnySchemaObject, dataCxt?: DataValidationCxt):
142
- | boolean
143
- | Promise<any>
142
+ (
143
+ schema: any,
144
+ data: any,
145
+ parentSchema?: AnySchemaObject,
146
+ dataCxt?: DataValidationCxt
147
+ ): boolean | Promise<any>
144
148
  errors?: Partial<ErrorObject>[]
145
149
  }
146
150
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ajv",
3
- "version": "8.12.0",
3
+ "version": "8.13.0",
4
4
  "description": "Another JSON Schema Validator",
5
5
  "main": "dist/ajv.js",
6
6
  "types": "dist/ajv.d.ts",
@@ -58,53 +58,53 @@
58
58
  "homepage": "https://ajv.js.org",
59
59
  "runkitExampleFilename": ".runkit_example.js",
60
60
  "dependencies": {
61
- "fast-deep-equal": "^3.1.1",
61
+ "fast-deep-equal": "^3.1.3",
62
62
  "json-schema-traverse": "^1.0.0",
63
63
  "require-from-string": "^2.0.2",
64
- "uri-js": "^4.2.2"
64
+ "uri-js": "^4.4.1"
65
65
  },
66
66
  "devDependencies": {
67
- "@ajv-validator/config": "^0.3.0",
68
- "@rollup/plugin-commonjs": "^24.0.0",
69
- "@rollup/plugin-json": "^6.0.0",
70
- "@rollup/plugin-node-resolve": "^15.0.1",
71
- "@rollup/plugin-typescript": "^10.0.1",
72
- "@types/chai": "^4.2.12",
73
- "@types/mocha": "^10.0.0",
74
- "@types/node": "^18.11.9",
75
- "@types/require-from-string": "^1.2.0",
76
- "@typescript-eslint/eslint-plugin": "^3.8.0",
77
- "@typescript-eslint/parser": "^3.8.0",
78
- "ajv-formats": "^3.0.0-rc.0",
67
+ "@ajv-validator/config": "^0.5.0",
68
+ "@rollup/plugin-commonjs": "^25.0.7",
69
+ "@rollup/plugin-json": "^6.1.0",
70
+ "@rollup/plugin-node-resolve": "^15.2.3",
71
+ "@rollup/plugin-typescript": "^11.1.6",
72
+ "@types/chai": "^4.3.11",
73
+ "@types/mocha": "^10.0.6",
74
+ "@types/node": "^20.11.30",
75
+ "@types/require-from-string": "^1.2.3",
76
+ "@typescript-eslint/eslint-plugin": "^7.3.1",
77
+ "@typescript-eslint/parser": "^7.3.1",
78
+ "ajv-formats": "^3.0.1",
79
79
  "browserify": "^17.0.0",
80
- "chai": "^4.0.1",
81
- "cross-env": "^7.0.2",
82
- "dayjs": "^1.10.4",
80
+ "chai": "^4.4.1",
81
+ "cross-env": "^7.0.3",
82
+ "dayjs": "^1.11.10",
83
83
  "dayjs-plugin-utc": "^0.1.2",
84
- "eslint": "^7.8.1",
85
- "eslint-config-prettier": "^7.0.0",
86
- "fast-uri": "^2.1.0",
87
- "glob": "^8.0.2",
88
- "husky": "^8.0.2",
89
- "if-node-version": "^1.0.0",
90
- "jimp": "^0.16.1",
91
- "js-beautify": "^1.7.3",
84
+ "eslint": "^8.57.0",
85
+ "eslint-config-prettier": "^9.1.0",
86
+ "fast-uri": "^2.3.0",
87
+ "glob": "^10.3.10",
88
+ "husky": "^9.0.11",
89
+ "if-node-version": "^1.1.1",
90
+ "jimp": "^0.22.10",
91
+ "js-beautify": "^1.15.1",
92
92
  "json-schema-test": "^2.0.0",
93
- "karma": "^6.0.0",
94
- "karma-chrome-launcher": "^3.0.0",
95
- "karma-mocha": "^2.0.0",
96
- "lint-staged": "^13.0.3",
97
- "mocha": "^10.0.0",
98
- "module-from-string": "^3.1.3",
99
- "node-fetch": "^3.0.0",
100
- "nyc": "^15.0.0",
101
- "prettier": "^2.3.1",
102
- "re2": "^1.16.0",
103
- "rollup": "^2.44.0",
93
+ "karma": "^6.4.2",
94
+ "karma-chrome-launcher": "^3.2.0",
95
+ "karma-mocha": "^2.0.1",
96
+ "lint-staged": "^15.2.2",
97
+ "mocha": "^10.3.0",
98
+ "module-from-string": "^3.3.0",
99
+ "node-fetch": "^3.3.2",
100
+ "nyc": "^15.1.0",
101
+ "prettier": "3.0.3",
102
+ "re2": "^1.20.9",
103
+ "rollup": "^2.79.1",
104
104
  "rollup-plugin-terser": "^7.0.2",
105
- "ts-node": "^10.0.0",
106
- "tsify": "^5.0.2",
107
- "typescript": "^4.8.0"
105
+ "ts-node": "^10.9.2",
106
+ "tsify": "^5.0.4",
107
+ "typescript": "5.3.3"
108
108
  },
109
109
  "collective": {
110
110
  "type": "opencollective",
package/package.json CHANGED
@@ -53,7 +53,7 @@
53
53
  "jsii-docgen": "^3.8.31",
54
54
  "jsii-pacmak": "^1.97.0",
55
55
  "jsii-rosetta": "5.3.x",
56
- "projen": "0.81.3",
56
+ "projen": "0.81.5",
57
57
  "standard-version": "^9",
58
58
  "ts-jest": "^27",
59
59
  "typescript": "^5"
@@ -84,7 +84,7 @@
84
84
  },
85
85
  "main": "lib/index.js",
86
86
  "license": "Apache-2.0",
87
- "version": "2.0.826",
87
+ "version": "2.0.828",
88
88
  "jest": {
89
89
  "testMatch": [
90
90
  "<rootDir>/src/**/__tests__/**/*.ts?(x)",