@redocly/openapi-core 2.48.0 → 2.49.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/lib/config/all.d.ts.map +1 -1
- package/lib/config/all.js +3 -0
- package/lib/config/all.js.map +1 -1
- package/lib/config/minimal.d.ts.map +1 -1
- package/lib/config/minimal.js +3 -0
- package/lib/config/minimal.js.map +1 -1
- package/lib/config/recommended-strict.d.ts.map +1 -1
- package/lib/config/recommended-strict.js +3 -0
- package/lib/config/recommended-strict.js.map +1 -1
- package/lib/config/recommended.d.ts.map +1 -1
- package/lib/config/recommended.js +3 -0
- package/lib/config/recommended.js.map +1 -1
- package/lib/config/spec.d.ts.map +1 -1
- package/lib/config/spec.js +3 -0
- package/lib/config/spec.js.map +1 -1
- package/lib/rules/oas3/index.d.ts.map +1 -1
- package/lib/rules/oas3/index.js +2 -0
- package/lib/rules/oas3/index.js.map +1 -1
- package/lib/rules/oas3/no-illogical-composition-keywords.d.ts +3 -0
- package/lib/rules/oas3/no-illogical-composition-keywords.d.ts.map +1 -0
- package/lib/rules/oas3/no-illogical-composition-keywords.js +358 -0
- package/lib/rules/oas3/no-illogical-composition-keywords.js.map +1 -0
- package/lib/types/index.d.ts +2 -1
- package/lib/types/index.d.ts.map +1 -1
- package/lib/types/index.js.map +1 -1
- package/lib/types/oas2.d.ts +6 -6
- package/lib/types/oas3.d.ts +27 -6
- package/lib/types/oas3.d.ts.map +1 -1
- package/lib/types/oas3.js +10 -9
- package/lib/types/oas3.js.map +1 -1
- package/lib/types/oas3_1.d.ts +27 -6
- package/lib/types/oas3_1.d.ts.map +1 -1
- package/lib/types/oas3_1.js +3 -3
- package/lib/types/oas3_1.js.map +1 -1
- package/lib/types/oas3_2.d.ts +27 -6
- package/lib/types/oas3_2.d.ts.map +1 -1
- package/lib/types/openrpc.d.ts +8 -8
- package/lib/types/redocly-yaml.d.ts +1 -1
- package/lib/types/redocly-yaml.d.ts.map +1 -1
- package/lib/types/redocly-yaml.js +1 -0
- package/lib/types/redocly-yaml.js.map +1 -1
- package/lib/visitors.d.ts +3 -0
- package/lib/visitors.d.ts.map +1 -1
- package/lib/visitors.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,358 @@
|
|
|
1
|
+
import { isRef } from '../../ref-utils.js';
|
|
2
|
+
import { dequal } from '../../utils/dequal.js';
|
|
3
|
+
import { getOwn } from '../../utils/get-own.js';
|
|
4
|
+
import { isDefined } from '../../utils/is-defined.js';
|
|
5
|
+
import { isPlainObject } from '../../utils/is-plain-object.js';
|
|
6
|
+
// Every keyword a schema may carry without stopping the comparison. A keyword outside this set
|
|
7
|
+
// could be the one that separates two schemas, so `hasUnsupportedConstraint` gives up on the pair.
|
|
8
|
+
// Membership therefore has two reasons: the checks read it, or it constrains no value at all.
|
|
9
|
+
const UNDERSTOOD_KEYWORDS = new Set([
|
|
10
|
+
'type',
|
|
11
|
+
'format',
|
|
12
|
+
'enum',
|
|
13
|
+
'const',
|
|
14
|
+
'nullable',
|
|
15
|
+
'properties',
|
|
16
|
+
'required',
|
|
17
|
+
'additionalProperties',
|
|
18
|
+
'discriminator',
|
|
19
|
+
'$ref',
|
|
20
|
+
'$id',
|
|
21
|
+
'$schema',
|
|
22
|
+
'$anchor',
|
|
23
|
+
'$comment',
|
|
24
|
+
'title',
|
|
25
|
+
'description',
|
|
26
|
+
'default',
|
|
27
|
+
'example',
|
|
28
|
+
'examples',
|
|
29
|
+
'deprecated',
|
|
30
|
+
'readOnly',
|
|
31
|
+
'writeOnly',
|
|
32
|
+
'externalDocs',
|
|
33
|
+
'xml',
|
|
34
|
+
]);
|
|
35
|
+
export const NoIllogicalCompositionKeywords = () => {
|
|
36
|
+
return {
|
|
37
|
+
AllOf(members, ctx) {
|
|
38
|
+
const parentSchema = ctx.parent;
|
|
39
|
+
if (!Array.isArray(members))
|
|
40
|
+
return;
|
|
41
|
+
if (members.length === 0 ||
|
|
42
|
+
(members.length === 1 &&
|
|
43
|
+
Object.keys(parentSchema).length === 1 &&
|
|
44
|
+
!isSubtypeOfDiscriminatedSchema(members[0], ctx.resolve))) {
|
|
45
|
+
reportSingleSchema(members, 'allOf', ctx);
|
|
46
|
+
}
|
|
47
|
+
reportEmptyMembers(members, 'allOf', ctx);
|
|
48
|
+
reportDuplicateMembers(members, 'allOf', ctx);
|
|
49
|
+
},
|
|
50
|
+
AnyOf(members, ctx) {
|
|
51
|
+
const parentSchema = ctx.parent;
|
|
52
|
+
if (!Array.isArray(members))
|
|
53
|
+
return;
|
|
54
|
+
const hasDiscriminator = isPlainObject(parentSchema.discriminator);
|
|
55
|
+
if (members.length < 2 && !hasDiscriminator) {
|
|
56
|
+
reportSingleSchema(members, 'anyOf', ctx);
|
|
57
|
+
}
|
|
58
|
+
reportEmptyMembers(members, 'anyOf', ctx);
|
|
59
|
+
reportDuplicateMembers(members, 'anyOf', ctx);
|
|
60
|
+
if (hasDiscriminator) {
|
|
61
|
+
reportInlineMembers(members, 'anyOf', ctx);
|
|
62
|
+
}
|
|
63
|
+
},
|
|
64
|
+
OneOf(members, ctx) {
|
|
65
|
+
const parentSchema = ctx.parent;
|
|
66
|
+
if (!Array.isArray(members))
|
|
67
|
+
return;
|
|
68
|
+
const { discriminator } = parentSchema;
|
|
69
|
+
const hasDiscriminator = isPlainObject(discriminator);
|
|
70
|
+
if (members.length < 2 && !hasDiscriminator) {
|
|
71
|
+
reportSingleSchema(members, 'oneOf', ctx);
|
|
72
|
+
}
|
|
73
|
+
reportEmptyMembers(members, 'oneOf', ctx);
|
|
74
|
+
reportDuplicateMembers(members, 'oneOf', ctx);
|
|
75
|
+
if (hasDiscriminator) {
|
|
76
|
+
reportInlineMembers(members, 'oneOf', ctx);
|
|
77
|
+
}
|
|
78
|
+
if (schemaAllowsNull(parentSchema)) {
|
|
79
|
+
reportNullableParent(members, ctx);
|
|
80
|
+
}
|
|
81
|
+
reportAmbiguousMembers(members, hasDiscriminator ? discriminator : undefined, ctx);
|
|
82
|
+
},
|
|
83
|
+
};
|
|
84
|
+
};
|
|
85
|
+
function reportSingleSchema(members, keyword, ctx) {
|
|
86
|
+
const suggestion = members.length === 1 ? ' Use the schema directly instead.' : '';
|
|
87
|
+
ctx.report({
|
|
88
|
+
message: `\`${keyword}\` should have at least two schemas.${suggestion}`,
|
|
89
|
+
location: ctx.location.key(),
|
|
90
|
+
});
|
|
91
|
+
}
|
|
92
|
+
function isSubtypeOfDiscriminatedSchema(member, resolve) {
|
|
93
|
+
return isPlainObject(resolveSchema(member, resolve)?.schema.discriminator);
|
|
94
|
+
}
|
|
95
|
+
function reportEmptyMembers(members, keyword, ctx) {
|
|
96
|
+
for (const [index, member] of members.entries()) {
|
|
97
|
+
if (isPlainObject(member) && Object.keys(member).length === 0) {
|
|
98
|
+
ctx.report({
|
|
99
|
+
message: `Schema in \`${keyword}\` is empty, so it matches any value.`,
|
|
100
|
+
location: ctx.location.child([index]),
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
function reportInlineMembers(members, keyword, ctx) {
|
|
106
|
+
for (const [index, member] of members.entries()) {
|
|
107
|
+
if (isRef(member) || (isPlainObject(member) && '$id' in member))
|
|
108
|
+
continue;
|
|
109
|
+
ctx.report({
|
|
110
|
+
message: `Schema in \`${keyword}\` is inline, so the \`discriminator\` cannot select it. Use a \`$ref\` to a named schema.`,
|
|
111
|
+
location: ctx.location.child([index]),
|
|
112
|
+
});
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
function reportDuplicateMembers(members, keyword, ctx) {
|
|
116
|
+
for (let index = 1; index < members.length; index++) {
|
|
117
|
+
const firstIndex = members.findIndex((other) => dequal(other, members[index]));
|
|
118
|
+
if (firstIndex < index) {
|
|
119
|
+
ctx.report({
|
|
120
|
+
message: `Schema in \`${keyword}\` duplicates the schema at position ${firstIndex + 1}.`,
|
|
121
|
+
location: ctx.location.child([index]),
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
function reportNullableParent(members, ctx) {
|
|
127
|
+
const nullableMember = members.some((member) => {
|
|
128
|
+
const resolved = resolveSchema(member, ctx.resolve);
|
|
129
|
+
return resolved ? schemaAllowsNull(resolved.schema) : false;
|
|
130
|
+
});
|
|
131
|
+
if (!nullableMember)
|
|
132
|
+
return;
|
|
133
|
+
ctx.report({
|
|
134
|
+
message: 'The schema and a schema in `oneOf` both accept `null`, so nothing decides which one applies to a null value.',
|
|
135
|
+
location: ctx.location.key(),
|
|
136
|
+
});
|
|
137
|
+
}
|
|
138
|
+
function reportAmbiguousMembers(members, discriminator, ctx) {
|
|
139
|
+
const { resolve, report, location } = ctx;
|
|
140
|
+
const shouldReportDiscriminatorGap = ctx.specVersion !== 'oas3_2';
|
|
141
|
+
const resolvedMembers = members.map((member) => resolveSchema(member, resolve));
|
|
142
|
+
for (let leftIndex = 0; leftIndex < resolvedMembers.length - 1; leftIndex++) {
|
|
143
|
+
const left = resolvedMembers[leftIndex];
|
|
144
|
+
if (!left)
|
|
145
|
+
continue;
|
|
146
|
+
for (let rightIndex = leftIndex + 1; rightIndex < resolvedMembers.length; rightIndex++) {
|
|
147
|
+
const right = resolvedMembers[rightIndex];
|
|
148
|
+
if (!right)
|
|
149
|
+
continue;
|
|
150
|
+
// Skip only pairs `reportDuplicateMembers` already reported, which compares raw nodes too.
|
|
151
|
+
if (dequal(members[leftIndex], members[rightIndex]))
|
|
152
|
+
continue;
|
|
153
|
+
const reason = findOverlapReason(left, right, resolve, discriminator, shouldReportDiscriminatorGap);
|
|
154
|
+
if (!reason)
|
|
155
|
+
continue;
|
|
156
|
+
report({
|
|
157
|
+
message: `Schemas in \`oneOf\` must be mutually exclusive. Found overlapping schemas: ${describeMember(members[leftIndex], leftIndex)} and ${describeMember(members[rightIndex], rightIndex)}. ${reason}`,
|
|
158
|
+
location: location.key(),
|
|
159
|
+
});
|
|
160
|
+
}
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
function describeMember(member, index) {
|
|
164
|
+
if (isRef(member))
|
|
165
|
+
return `\`${member.$ref}\``;
|
|
166
|
+
if (member.title)
|
|
167
|
+
return `\`${member.title}\``;
|
|
168
|
+
return `schema at position ${index + 1}`;
|
|
169
|
+
}
|
|
170
|
+
function findOverlapReason(left, right, resolve, discriminator, shouldReportDiscriminatorGap) {
|
|
171
|
+
const leftSchema = left.schema;
|
|
172
|
+
const rightSchema = right.schema;
|
|
173
|
+
if (hasUnsupportedConstraint(leftSchema) || hasUnsupportedConstraint(rightSchema))
|
|
174
|
+
return null;
|
|
175
|
+
if (areExclusive(leftSchema, rightSchema))
|
|
176
|
+
return null;
|
|
177
|
+
if (schemaAllowsNull(leftSchema) && schemaAllowsNull(rightSchema)) {
|
|
178
|
+
return 'Both schemas accept `null`.';
|
|
179
|
+
}
|
|
180
|
+
const leftValues = readAllowedValues(leftSchema);
|
|
181
|
+
const rightValues = readAllowedValues(rightSchema);
|
|
182
|
+
if (leftValues && rightValues) {
|
|
183
|
+
const shared = leftValues.filter((value) => rightValues.some((other) => dequal(value, other)));
|
|
184
|
+
return `Both schemas allow the values ${JSON.stringify(shared)}.`;
|
|
185
|
+
}
|
|
186
|
+
if (discriminator) {
|
|
187
|
+
return shouldReportDiscriminatorGap
|
|
188
|
+
? describeDiscriminatorGap(leftSchema, rightSchema, discriminator)
|
|
189
|
+
: null;
|
|
190
|
+
}
|
|
191
|
+
const propertyOverlap = findPropertyOverlap(left, right, resolve);
|
|
192
|
+
if (propertyOverlap)
|
|
193
|
+
return propertyOverlap;
|
|
194
|
+
if (!leftSchema.properties && !rightSchema.properties) {
|
|
195
|
+
const sharedTypes = getSharedTypes(leftSchema, rightSchema);
|
|
196
|
+
if (sharedTypes?.length) {
|
|
197
|
+
return `Both schemas accept ${sharedTypes.map((type) => `\`${type}\``).join(', ')}.`;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
return null;
|
|
201
|
+
}
|
|
202
|
+
function describeDiscriminatorGap(left, right, discriminator) {
|
|
203
|
+
const { propertyName } = discriminator;
|
|
204
|
+
// `struct` is not guaranteed to have rejected a non-string `propertyName` first.
|
|
205
|
+
if (typeof propertyName !== 'string')
|
|
206
|
+
return null;
|
|
207
|
+
const isRequiredInBoth = !!left.required?.includes(propertyName) && !!right.required?.includes(propertyName);
|
|
208
|
+
if (isRequiredInBoth)
|
|
209
|
+
return null;
|
|
210
|
+
const isDeclaredInBoth = isDefined(getOwn(left.properties ?? {}, propertyName)) &&
|
|
211
|
+
isDefined(getOwn(right.properties ?? {}, propertyName));
|
|
212
|
+
if (!isDeclaredInBoth) {
|
|
213
|
+
return `Declare \`${propertyName}\` in every schema and add it to \`required\`; the \`discriminator\` cannot read a property a value may omit.`;
|
|
214
|
+
}
|
|
215
|
+
return `Add \`${propertyName}\` to \`required\` in every schema; the \`discriminator\` cannot read a property a value may omit.`;
|
|
216
|
+
}
|
|
217
|
+
function findPropertyOverlap(left, right, resolve) {
|
|
218
|
+
const comparison = collectPropertyComparison(left, right);
|
|
219
|
+
if (!comparison)
|
|
220
|
+
return null;
|
|
221
|
+
if (forbidsPropertyRequiredBy(left.schema, comparison.leftProperties, comparison.rightRequired)) {
|
|
222
|
+
return null;
|
|
223
|
+
}
|
|
224
|
+
if (forbidsPropertyRequiredBy(right.schema, comparison.rightProperties, comparison.leftRequired)) {
|
|
225
|
+
return null;
|
|
226
|
+
}
|
|
227
|
+
if (schemasRequireDifferentProperties(comparison))
|
|
228
|
+
return null;
|
|
229
|
+
if (comparison.sharedNames.length === 0)
|
|
230
|
+
return null;
|
|
231
|
+
const shared = classifySharedProperties(comparison, resolve);
|
|
232
|
+
if (!shared)
|
|
233
|
+
return null;
|
|
234
|
+
const { optionalDistinguishingNames, ambiguousNames } = shared;
|
|
235
|
+
if (optionalDistinguishingNames.length > 0) {
|
|
236
|
+
const alsoShared = ambiguousNames.length > 0 ? ` Other shared properties: ${quoteAll(ambiguousNames)}.` : '';
|
|
237
|
+
return `Add ${quoteAll(optionalDistinguishingNames)} to \`required\` in every schema; an optional property cannot distinguish the schemas.${alsoShared}`;
|
|
238
|
+
}
|
|
239
|
+
if (ambiguousNames.length > 0) {
|
|
240
|
+
return `Both schemas define ${quoteAll(ambiguousNames)} without constraints that exclude each other. Add a discriminator, or constrain the shared properties to different values.`;
|
|
241
|
+
}
|
|
242
|
+
return null;
|
|
243
|
+
}
|
|
244
|
+
function collectPropertyComparison(left, right) {
|
|
245
|
+
const leftProperties = left.schema.properties;
|
|
246
|
+
const rightProperties = right.schema.properties;
|
|
247
|
+
if (!leftProperties || !rightProperties)
|
|
248
|
+
return null;
|
|
249
|
+
return {
|
|
250
|
+
leftSource: left.source,
|
|
251
|
+
rightSource: right.source,
|
|
252
|
+
leftProperties,
|
|
253
|
+
rightProperties,
|
|
254
|
+
leftRequired: new Set(left.schema.required ?? []),
|
|
255
|
+
rightRequired: new Set(right.schema.required ?? []),
|
|
256
|
+
sharedNames: Object.keys(leftProperties).filter((name) => getOwn(rightProperties, name)),
|
|
257
|
+
};
|
|
258
|
+
}
|
|
259
|
+
function schemasRequireDifferentProperties({ leftProperties, rightProperties, leftRequired, rightRequired, }) {
|
|
260
|
+
const leftRequiresPropertyUnknownToRight = [...leftRequired].some((name) => !getOwn(rightProperties, name) && !rightRequired.has(name));
|
|
261
|
+
const rightRequiresPropertyUnknownToLeft = [...rightRequired].some((name) => !getOwn(leftProperties, name) && !leftRequired.has(name));
|
|
262
|
+
return leftRequiresPropertyUnknownToRight && rightRequiresPropertyUnknownToLeft;
|
|
263
|
+
}
|
|
264
|
+
function classifySharedProperties({ leftSource, rightSource, leftProperties, rightProperties, leftRequired, rightRequired, sharedNames, }, resolve) {
|
|
265
|
+
const optionalDistinguishingNames = [];
|
|
266
|
+
const ambiguousNames = [];
|
|
267
|
+
for (const name of sharedNames) {
|
|
268
|
+
const isRequiredInBoth = leftRequired.has(name) && rightRequired.has(name);
|
|
269
|
+
const leftProperty = resolveSchema(getOwn(leftProperties, name), resolve, leftSource);
|
|
270
|
+
const rightProperty = resolveSchema(getOwn(rightProperties, name), resolve, rightSource);
|
|
271
|
+
if (!leftProperty || !rightProperty)
|
|
272
|
+
continue;
|
|
273
|
+
if (hasUnsupportedConstraint(leftProperty.schema) ||
|
|
274
|
+
hasUnsupportedConstraint(rightProperty.schema)) {
|
|
275
|
+
continue;
|
|
276
|
+
}
|
|
277
|
+
if (areExclusive(leftProperty.schema, rightProperty.schema)) {
|
|
278
|
+
if (isRequiredInBoth)
|
|
279
|
+
return null;
|
|
280
|
+
optionalDistinguishingNames.push(name);
|
|
281
|
+
continue;
|
|
282
|
+
}
|
|
283
|
+
ambiguousNames.push(name);
|
|
284
|
+
}
|
|
285
|
+
return { optionalDistinguishingNames, ambiguousNames };
|
|
286
|
+
}
|
|
287
|
+
function forbidsPropertyRequiredBy(schema, declaredProperties, required) {
|
|
288
|
+
if (schema.additionalProperties !== false)
|
|
289
|
+
return false;
|
|
290
|
+
return [...required].some((name) => !getOwn(declaredProperties, name));
|
|
291
|
+
}
|
|
292
|
+
function areExclusive(left, right) {
|
|
293
|
+
const leftValues = readAllowedValues(left);
|
|
294
|
+
const rightValues = readAllowedValues(right);
|
|
295
|
+
if (leftValues && rightValues) {
|
|
296
|
+
return !leftValues.some((value) => rightValues.some((other) => dequal(value, other)));
|
|
297
|
+
}
|
|
298
|
+
return getSharedTypes(left, right)?.length === 0;
|
|
299
|
+
}
|
|
300
|
+
function resolveSchema(member, resolve, from) {
|
|
301
|
+
if (isRef(member)) {
|
|
302
|
+
const { node, location } = resolve(member, from);
|
|
303
|
+
return isPlainObject(node) ? { schema: node, source: location?.source.absoluteRef } : undefined;
|
|
304
|
+
}
|
|
305
|
+
// JSON Schema allows `true` and `false` as schemas; these checks only read object schemas.
|
|
306
|
+
return isPlainObject(member) ? { schema: member, source: from } : undefined;
|
|
307
|
+
}
|
|
308
|
+
function hasUnsupportedConstraint(schema) {
|
|
309
|
+
return Object.keys(schema).some((keyword) => !UNDERSTOOD_KEYWORDS.has(keyword) && !keyword.startsWith('x-'));
|
|
310
|
+
}
|
|
311
|
+
function isNullable(schema) {
|
|
312
|
+
return 'nullable' in schema && schema.nullable === true;
|
|
313
|
+
}
|
|
314
|
+
function getTypeSet(schema) {
|
|
315
|
+
const declaredType = schema.type;
|
|
316
|
+
if (declaredType === undefined)
|
|
317
|
+
return undefined;
|
|
318
|
+
const types = new Set(Array.isArray(declaredType) ? declaredType : [declaredType]);
|
|
319
|
+
if (isNullable(schema))
|
|
320
|
+
types.add('null');
|
|
321
|
+
return types;
|
|
322
|
+
}
|
|
323
|
+
function getSharedTypes(left, right) {
|
|
324
|
+
const leftTypes = getTypeSet(left);
|
|
325
|
+
const rightTypes = getTypeSet(right);
|
|
326
|
+
if (!leftTypes || !rightTypes)
|
|
327
|
+
return undefined;
|
|
328
|
+
const shared = [...leftTypes].filter((type) => rightTypes.has(type));
|
|
329
|
+
if (shared.length === 0 && integerMeetsNumber(left, right))
|
|
330
|
+
return ['integer'];
|
|
331
|
+
return shared;
|
|
332
|
+
}
|
|
333
|
+
function integerMeetsNumber(left, right) {
|
|
334
|
+
const leftTypes = getTypeSet(left);
|
|
335
|
+
const rightTypes = getTypeSet(right);
|
|
336
|
+
if (leftTypes?.has('integer') && rightTypes?.has('number'))
|
|
337
|
+
return allowsInteger(right);
|
|
338
|
+
if (leftTypes?.has('number') && rightTypes?.has('integer'))
|
|
339
|
+
return allowsInteger(left);
|
|
340
|
+
return false;
|
|
341
|
+
}
|
|
342
|
+
function allowsInteger(schema) {
|
|
343
|
+
const values = readAllowedValues(schema);
|
|
344
|
+
return !values || values.some((value) => typeof value === 'number' && Number.isInteger(value));
|
|
345
|
+
}
|
|
346
|
+
function schemaAllowsNull(schema) {
|
|
347
|
+
return isNullable(schema) || getTypeSet(schema)?.has('null') === true;
|
|
348
|
+
}
|
|
349
|
+
function readAllowedValues(schema) {
|
|
350
|
+
if (schema.enum)
|
|
351
|
+
return schema.enum;
|
|
352
|
+
const constValue = 'const' in schema ? schema.const : undefined;
|
|
353
|
+
return isDefined(constValue) ? [constValue] : undefined;
|
|
354
|
+
}
|
|
355
|
+
function quoteAll(names) {
|
|
356
|
+
return names.map((name) => `\`${name}\``).join(', ');
|
|
357
|
+
}
|
|
358
|
+
//# sourceMappingURL=no-illogical-composition-keywords.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"no-illogical-composition-keywords.js","sourceRoot":"","sources":["../../../src/rules/oas3/no-illogical-composition-keywords.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAO3C,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAC;AAC/C,OAAO,EAAE,MAAM,EAAE,MAAM,wBAAwB,CAAC;AAChD,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAAE,aAAa,EAAE,MAAM,gCAAgC,CAAC;AAwB/D,+FAA+F;AAC/F,mGAAmG;AACnG,8FAA8F;AAC9F,MAAM,mBAAmB,GAAwB,IAAI,GAAG,CAAwC;IAC9F,MAAM;IACN,QAAQ;IACR,MAAM;IACN,OAAO;IACP,UAAU;IACV,YAAY;IACZ,UAAU;IACV,sBAAsB;IACtB,eAAe;IACf,MAAM;IACN,KAAK;IACL,SAAS;IACT,SAAS;IACT,UAAU;IACV,OAAO;IACP,aAAa;IACb,SAAS;IACT,SAAS;IACT,UAAU;IACV,YAAY;IACZ,UAAU;IACV,WAAW;IACX,cAAc;IACd,KAAK;CACN,CAAC,CAAC;AAEH,MAAM,CAAC,MAAM,8BAA8B,GAAa,GAAG,EAAE;IAC3D,OAAO;QACL,KAAK,CAAC,OAAO,EAAE,GAAG;YAChB,MAAM,YAAY,GAAG,GAAG,CAAC,MAA2B,CAAC;YACrD,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC;gBAAE,OAAO;YAEpC,IACE,OAAO,CAAC,MAAM,KAAK,CAAC;gBACpB,CAAC,OAAO,CAAC,MA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AS,CAAC;QAAE,OAAO,aAAa,CAAC,IAAI,CAAC,CAAC;IAEvF,OAAO,KAAK,CAAC;AACf,CAAC;AAED,SAAS,aAAa,CAAC,MAAyB;IAC9C,MAAM,MAAM,GAAG,iBAAiB,CAAC,MAAM,CAAC,CAAC;IACzC,OAAO,CAAC,MAAM,IAAI,MAAM,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,OAAO,KAAK,KAAK,QAAQ,IAAI,MAAM,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;AACjG,CAAC;AAED,SAAS,gBAAgB,CAAC,MAAyB;IACjD,OAAO,UAAU,CAAC,MAAM,CAAC,IAAI,UAAU,CAAC,MAAM,CAAC,EAAE,GAAG,CAAC,MAAM,CAAC,KAAK,IAAI,CAAC;AACxE,CAAC;AAED,SAAS,iBAAiB,CAAC,MAAyB;IAClD,IAAI,MAAM,CAAC,IAAI;QAAE,OAAO,MAAM,CAAC,IAAI,CAAC;IACpC,MAAM,UAAU,GAAG,OAAO,IAAI,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS,CAAC;IAChE,OAAO,SAAS,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC;AAC1D,CAAC;AAED,SAAS,QAAQ,CAAC,KAAe;IAC/B,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,KAAK,IAAI,IAAI,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACvD,CAAC"}
|
package/lib/types/index.d.ts
CHANGED
|
@@ -50,12 +50,13 @@ export type NormalizedNodeType = {
|
|
|
50
50
|
type NormalizedPropType = NormalizedNodeType | NormalizedScalarSchema | null | undefined;
|
|
51
51
|
type NormalizedResolveTypeFn = (value: any, key: string) => NormalizedPropType;
|
|
52
52
|
export declare function listOf(typeName: string, opts?: {
|
|
53
|
+
name?: string;
|
|
53
54
|
description?: string;
|
|
54
55
|
documentationLink?: string;
|
|
55
56
|
}): {
|
|
57
|
+
name: string;
|
|
56
58
|
description?: string;
|
|
57
59
|
documentationLink?: string;
|
|
58
|
-
name: string;
|
|
59
60
|
properties: {};
|
|
60
61
|
items: string;
|
|
61
62
|
};
|
package/lib/types/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,YAAY,GAAG;IACzB,IAAI,CAAC,EAAE,KAAK,CAAC;IACb,IAAI,CAAC,EAAE,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,OAAO,CAAC;IACxE,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,CAAC;AAEF,MAAM,MAAM,sBAAsB,GAAG;IACnC,IAAI,CAAC,EAAE,KAAK,CAAC;IACb,IAAI,CAAC,EAAE,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,GAAG,QAAQ,GAAG,OAAO,CAAC;IACxE,KAAK,CAAC,EAAE,sBAAsB,CAAC;IAC/B,IAAI,CAAC,EAAE,MAAM,EAAE,CAAC;IAChB,eAAe,CAAC,EAAE,kBAAkB,CAAC;IACrC,UAAU,EAAE,OAAO,CAAC;IACpB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5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;kBAApE,MAAM;wBAAsB,MAAM;uBAAqB,MAAM;;;;EAQpF;AAED,eAAO,MAAM,aAAa,EAAE,kBAK3B,CAAC;AAEF,wBAAgB,cAAc,CAC5B,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,QAAQ,CAAC,EAC/B,OAAO,GAAE;IAAE,oBAAoB,CAAC,EAAE,OAAO,CAAA;CAAO,GAC/C,MAAM,CAAC,MAAM,EAAE,kBAAkB,CAAC,CAoEpC;AAED,wBAAgB,WAAW,CAAC,CAAC,EAAE,kBAAkB,GAAG,CAAC,IAAI,kBAAkB,CAE1E"}
|
package/lib/types/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAwDA,MAAM,UAAU,MAAM,CACpB,QAAgB,EAChB,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAwDA,MAAM,UAAU,MAAM,CACpB,QAAgB,EAChB,OAA4E,EAAE;IAE9E,OAAO;QACL,IAAI,EAAE,GAAG,QAAQ,MAAM;QACvB,UAAU,EAAE,EAAE;QACd,KAAK,EAAE,QAAQ;QACf,GAAG,IAAI;KACR,CAAC;AACJ,CAAC;AAED,MAAM,UAAU,KAAK,CACnB,QAAgB,EAChB,OAAwF,EAAE;IAE1F,OAAO;QACL,IAAI,EAAE,GAAG,QAAQ,KAAK;QACtB,UAAU,EAAE,EAAE;QACd,oBAAoB,EAAE,GAAG,EAAE,CAAC,QAAQ;QACpC,GAAG,IAAI;KACR,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,aAAa,GAAuB;IAC/C,IAAI,EAAE,eAAe;IACrB,UAAU,EAAE,EAAE;IACd,kEAAkE;IAClE,oBAAoB,EAAE,EAAE,UAAU,EAAE,IAAI,EAAE;CAC3C,CAAC;AAEF,MAAM,UAAU,cAAc,CAC5B,KAA+B,EAC/B,UAA8C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AAI,CAAC,UAAU,GAAG,WAAW,CAAC;QAChC,CAAC;IACH,CAAC;IAED,8BAA8B;IAC9B,SAAS,WAAW,CAClB,IAA2D;QAE3D,IAAI,OAAO,IAAI,KAAK,QAAQ,EAAE,CAAC;YAC7B,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,EAAE,CAAC;gBAC3B,MAAM,IAAI,KAAK,CAAC,4BAA4B,IAAI,EAAE,CAAC,CAAC;YACtD,CAAC;YACD,OAAO,eAAe,CAAC,IAAI,CAAC,CAAC;QAC/B,CAAC;aAAM,IAAI,OAAO,IAAI,KAAK,UAAU,EAAE,CAAC;YACtC,OAAO,CAAC,KAAc,EAAE,GAAW,EAAE,EAAE,CACrC,WAAW,CAAE,IAAgC,CAAC,KAAK,EAAE,GAAG,CAAC,CAAuB,CAAC;QACrF,CAAC;aAAM,IAAI,WAAW,CAAC,IAAI,CAAC,EAAE,CAAC;YAC7B,IAAI,GAAG,EAAE,GAAG,IAAI,EAAE,CAAC;YACnB,aAAa,CAAC,IAAI,CAAC,CAAC;YACpB,OAAO,IAAI,CAAC;QACd,CAAC;aAAM,IAAI,IAAI,EAAE,eAAe,KAAK,SAAS,EAAE,CAAC;YAC/C,OAAO;gBACL,GAAG,IAAI;gBACP,eAAe,EAAE,CAAC,WAAW,CAAC,IAAI,CAAC,eAAe,CAAC,IAAI,SAAS,CAAuB;aACxF,CAAC;QACJ,CAAC;aAAM,CAAC;YACN,OAAO,IAAI,CAAC;QACd,CAAC;IACH,CAAC;AACH,CAAC;AAED,MAAM,UAAU,WAAW,CAAC,CAAqB;IAC/C,OAAO,OAAO,CAAC,EAAE,IAAI,KAAK,QAAQ,CAAC;AACrC,CAAC"}
|
package/lib/types/oas2.d.ts
CHANGED
|
@@ -3,16 +3,16 @@ export declare const Oas2Types: {
|
|
|
3
3
|
readonly Root: NodeType;
|
|
4
4
|
readonly Tag: NodeType;
|
|
5
5
|
readonly TagList: {
|
|
6
|
+
name: string;
|
|
6
7
|
description?: string;
|
|
7
8
|
documentationLink?: string;
|
|
8
|
-
name: string;
|
|
9
9
|
properties: {};
|
|
10
10
|
items: string;
|
|
11
11
|
};
|
|
12
12
|
readonly TagGroups: {
|
|
13
|
+
name: string;
|
|
13
14
|
description?: string;
|
|
14
15
|
documentationLink?: string;
|
|
15
|
-
name: string;
|
|
16
16
|
properties: {};
|
|
17
17
|
items: string;
|
|
18
18
|
};
|
|
@@ -30,9 +30,9 @@ export declare const Oas2Types: {
|
|
|
30
30
|
readonly EnumDescriptions: NodeType;
|
|
31
31
|
readonly SecurityRequirement: NodeType;
|
|
32
32
|
readonly SecurityRequirementList: {
|
|
33
|
+
name: string;
|
|
33
34
|
description?: string;
|
|
34
35
|
documentationLink?: string;
|
|
35
|
-
name: string;
|
|
36
36
|
properties: {};
|
|
37
37
|
items: string;
|
|
38
38
|
};
|
|
@@ -45,9 +45,9 @@ export declare const Oas2Types: {
|
|
|
45
45
|
readonly Parameter: NodeType;
|
|
46
46
|
readonly ParameterItems: NodeType;
|
|
47
47
|
readonly ParameterList: {
|
|
48
|
+
name: string;
|
|
48
49
|
description?: string;
|
|
49
50
|
documentationLink?: string;
|
|
50
|
-
name: string;
|
|
51
51
|
properties: {};
|
|
52
52
|
items: string;
|
|
53
53
|
};
|
|
@@ -95,16 +95,16 @@ export declare const Oas2Types: {
|
|
|
95
95
|
readonly Scopes: NodeType;
|
|
96
96
|
readonly XCodeSample: NodeType;
|
|
97
97
|
readonly XCodeSampleList: {
|
|
98
|
+
name: string;
|
|
98
99
|
description?: string;
|
|
99
100
|
documentationLink?: string;
|
|
100
|
-
name: string;
|
|
101
101
|
properties: {};
|
|
102
102
|
items: string;
|
|
103
103
|
};
|
|
104
104
|
readonly XServerList: {
|
|
105
|
+
name: string;
|
|
105
106
|
description?: string;
|
|
106
107
|
documentationLink?: string;
|
|
107
|
-
name: string;
|
|
108
108
|
properties: {};
|
|
109
109
|
items: string;
|
|
110
110
|
};
|
package/lib/types/oas3.d.ts
CHANGED
|
@@ -3,16 +3,16 @@ export declare const Oas3Types: {
|
|
|
3
3
|
readonly Root: NodeType;
|
|
4
4
|
readonly Tag: NodeType;
|
|
5
5
|
readonly TagList: {
|
|
6
|
+
name: string;
|
|
6
7
|
description?: string;
|
|
7
8
|
documentationLink?: string;
|
|
8
|
-
name: string;
|
|
9
9
|
properties: {};
|
|
10
10
|
items: string;
|
|
11
11
|
};
|
|
12
12
|
readonly TagGroups: {
|
|
13
|
+
name: string;
|
|
13
14
|
description?: string;
|
|
14
15
|
documentationLink?: string;
|
|
15
|
-
name: string;
|
|
16
16
|
properties: {};
|
|
17
17
|
items: string;
|
|
18
18
|
};
|
|
@@ -20,9 +20,9 @@ export declare const Oas3Types: {
|
|
|
20
20
|
readonly ExternalDocs: NodeType;
|
|
21
21
|
readonly Server: NodeType;
|
|
22
22
|
readonly ServerList: {
|
|
23
|
+
name: string;
|
|
23
24
|
description?: string;
|
|
24
25
|
documentationLink?: string;
|
|
25
|
-
name: string;
|
|
26
26
|
properties: {};
|
|
27
27
|
items: string;
|
|
28
28
|
};
|
|
@@ -37,9 +37,9 @@ export declare const Oas3Types: {
|
|
|
37
37
|
};
|
|
38
38
|
readonly SecurityRequirement: NodeType;
|
|
39
39
|
readonly SecurityRequirementList: {
|
|
40
|
+
name: string;
|
|
40
41
|
description?: string;
|
|
41
42
|
documentationLink?: string;
|
|
42
|
-
name: string;
|
|
43
43
|
properties: {};
|
|
44
44
|
items: string;
|
|
45
45
|
};
|
|
@@ -50,9 +50,9 @@ export declare const Oas3Types: {
|
|
|
50
50
|
readonly PathItem: NodeType;
|
|
51
51
|
readonly Parameter: NodeType;
|
|
52
52
|
readonly ParameterList: {
|
|
53
|
+
name: string;
|
|
53
54
|
description?: string;
|
|
54
55
|
documentationLink?: string;
|
|
55
|
-
name: string;
|
|
56
56
|
properties: {};
|
|
57
57
|
items: string;
|
|
58
58
|
};
|
|
@@ -109,6 +109,27 @@ export declare const Oas3Types: {
|
|
|
109
109
|
readonly Link: NodeType;
|
|
110
110
|
readonly Logo: NodeType;
|
|
111
111
|
readonly Schema: NodeType;
|
|
112
|
+
readonly AllOf: {
|
|
113
|
+
name: string;
|
|
114
|
+
description?: string;
|
|
115
|
+
documentationLink?: string;
|
|
116
|
+
properties: {};
|
|
117
|
+
items: string;
|
|
118
|
+
};
|
|
119
|
+
readonly AnyOf: {
|
|
120
|
+
name: string;
|
|
121
|
+
description?: string;
|
|
122
|
+
documentationLink?: string;
|
|
123
|
+
properties: {};
|
|
124
|
+
items: string;
|
|
125
|
+
};
|
|
126
|
+
readonly OneOf: {
|
|
127
|
+
name: string;
|
|
128
|
+
description?: string;
|
|
129
|
+
documentationLink?: string;
|
|
130
|
+
properties: {};
|
|
131
|
+
items: string;
|
|
132
|
+
};
|
|
112
133
|
readonly Xml: NodeType;
|
|
113
134
|
readonly SchemaProperties: NodeType;
|
|
114
135
|
readonly DiscriminatorMapping: NodeType;
|
|
@@ -202,9 +223,9 @@ export declare const Oas3Types: {
|
|
|
202
223
|
readonly SecurityScheme: NodeType;
|
|
203
224
|
readonly XCodeSample: NodeType;
|
|
204
225
|
readonly XCodeSampleList: {
|
|
226
|
+
name: string;
|
|
205
227
|
description?: string;
|
|
206
228
|
documentationLink?: string;
|
|
207
|
-
name: string;
|
|
208
229
|
properties: {};
|
|
209
230
|
items: string;
|
|
210
231
|
};
|
package/lib/types/oas3.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"oas3.d.ts","sourceRoot":"","sources":["../../src/types/oas3.ts"],"names":[],"mappings":"AACA,OAAO,EAAiB,KAAK,QAAQ,EAAE,MAAM,YAAY,CAAC;
|
|
1
|
+
{"version":3,"file":"oas3.d.ts","sourceRoot":"","sources":["../../src/types/oas3.ts"],"names":[],"mappings":"AACA,OAAO,EAAiB,KAAK,QAAQ,EAAE,MAAM,YAAY,CAAC;AA21B1D,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAiFZ,CAAC"}
|
package/lib/types/oas3.js
CHANGED
|
@@ -484,6 +484,10 @@ const Link = {
|
|
|
484
484
|
documentationLink: 'https://redocly.com/learn/openapi/openapi-visual-reference/links',
|
|
485
485
|
description: 'The Link object represents a possible design-time link for a response. The presence of a link does not guarantee the caller’s ability to successfully invoke it, rather it provides a known relationship and traversal mechanism between responses and other operations.',
|
|
486
486
|
};
|
|
487
|
+
const compositionDescription = 'Inline or referenced schema MUST be of a Schema Object and not a standard JSON Schema.';
|
|
488
|
+
const AllOf = listOf('Schema', { name: 'AllOf', description: compositionDescription });
|
|
489
|
+
const AnyOf = listOf('Schema', { name: 'AnyOf', description: compositionDescription });
|
|
490
|
+
const OneOf = listOf('Schema', { name: 'OneOf', description: compositionDescription });
|
|
487
491
|
// draft-00
|
|
488
492
|
const Schema = {
|
|
489
493
|
properties: {
|
|
@@ -515,15 +519,9 @@ const Schema = {
|
|
|
515
519
|
enum: ['object', 'array', 'string', 'number', 'integer', 'boolean'],
|
|
516
520
|
description: 'Value MUST be a string. Multiple types via an array are not supported.',
|
|
517
521
|
},
|
|
518
|
-
allOf:
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
anyOf: listOf('Schema', {
|
|
522
|
-
description: 'Inline or referenced schema MUST be of a Schema Object and not a standard JSON Schema.',
|
|
523
|
-
}),
|
|
524
|
-
oneOf: listOf('Schema', {
|
|
525
|
-
description: 'Inline or referenced schema MUST be of a Schema Object and not a standard JSON Schema.',
|
|
526
|
-
}),
|
|
522
|
+
allOf: AllOf,
|
|
523
|
+
anyOf: AnyOf,
|
|
524
|
+
oneOf: OneOf,
|
|
527
525
|
not: 'Schema',
|
|
528
526
|
properties: 'SchemaProperties',
|
|
529
527
|
items: (value) => {
|
|
@@ -802,6 +800,9 @@ export const Oas3Types = {
|
|
|
802
800
|
Link,
|
|
803
801
|
Logo,
|
|
804
802
|
Schema,
|
|
803
|
+
AllOf,
|
|
804
|
+
AnyOf,
|
|
805
|
+
OneOf,
|
|
805
806
|
Xml,
|
|
806
807
|
SchemaProperties,
|
|
807
808
|
DiscriminatorMapping,
|