зеркало из https://github.com/Azure/autorest.git
Fix: Only act as a warning if using AND security schemes (#4110)
This commit is contained in:
Родитель
4790de64e5
Коммит
9579610bed
|
@ -1,11 +0,0 @@
|
|||
{
|
||||
"changes": [
|
||||
{
|
||||
"packageName": "@autorest/core",
|
||||
"comment": "**Fix** Uncaught promise exception",
|
||||
"type": "patch"
|
||||
}
|
||||
],
|
||||
"packageName": "@autorest/core",
|
||||
"email": "tiguerin@microsoft.com"
|
||||
}
|
|
@ -41,7 +41,7 @@
|
|||
"typings": "./dist/exports.d.ts",
|
||||
"devDependencies": {
|
||||
"@autorest/configuration": "~1.3.0",
|
||||
"@autorest/core": "~3.4.0",
|
||||
"@autorest/core": "~3.4.1",
|
||||
"@azure-tools/async-io": "~3.0.0",
|
||||
"@azure-tools/extension": "~3.2.6",
|
||||
"@azure-tools/tasks": "~3.0.0",
|
||||
|
|
|
@ -1,6 +1,18 @@
|
|||
{
|
||||
"name": "@autorest/core",
|
||||
"entries": [
|
||||
{
|
||||
"version": "3.4.1",
|
||||
"tag": "@autorest/core_v3.4.1",
|
||||
"date": "Tue, 04 May 2021 18:18:45 GMT",
|
||||
"comments": {
|
||||
"patch": [
|
||||
{
|
||||
"comment": "**Fix** Uncaught promise exception"
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"version": "3.4.0",
|
||||
"tag": "@autorest/core_v3.4.0",
|
||||
|
|
|
@ -1,6 +1,13 @@
|
|||
# Change Log - @autorest/core
|
||||
|
||||
This log was last generated on Tue, 27 Apr 2021 17:48:43 GMT and should not be manually modified.
|
||||
This log was last generated on Tue, 04 May 2021 18:18:45 GMT and should not be manually modified.
|
||||
|
||||
## 3.4.1
|
||||
Tue, 04 May 2021 18:18:45 GMT
|
||||
|
||||
### Patches
|
||||
|
||||
- **Fix** Uncaught promise exception
|
||||
|
||||
## 3.4.0
|
||||
Tue, 27 Apr 2021 17:48:43 GMT
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "@autorest/core",
|
||||
"version": "3.4.0",
|
||||
"version": "3.4.1",
|
||||
"description": "AutoRest core module",
|
||||
"engines": {
|
||||
"node": ">=10.13.0"
|
||||
|
|
|
@ -1,6 +1,18 @@
|
|||
{
|
||||
"name": "@autorest/modelerfour",
|
||||
"entries": [
|
||||
{
|
||||
"version": "4.19.1",
|
||||
"tag": "@autorest/modelerfour_v4.19.1",
|
||||
"date": "Tue, 04 May 2021 18:18:45 GMT",
|
||||
"comments": {
|
||||
"patch": [
|
||||
{
|
||||
"comment": "**Fix** Using multiple security layers(`AND`) now produce warning instead of error."
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
{
|
||||
"version": "4.19.0",
|
||||
"tag": "@autorest/modelerfour_v4.19.0",
|
||||
|
|
|
@ -1,6 +1,13 @@
|
|||
# Change Log - @autorest/modelerfour
|
||||
|
||||
This log was last generated on Tue, 27 Apr 2021 17:48:43 GMT and should not be manually modified.
|
||||
This log was last generated on Tue, 04 May 2021 18:18:45 GMT and should not be manually modified.
|
||||
|
||||
## 4.19.1
|
||||
Tue, 04 May 2021 18:18:45 GMT
|
||||
|
||||
### Patches
|
||||
|
||||
- **Fix** Using multiple security layers(`AND`) now produce warning instead of error.
|
||||
|
||||
## 4.19.0
|
||||
Tue, 27 Apr 2021 17:48:43 GMT
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "@autorest/modelerfour",
|
||||
"version": "4.19.0",
|
||||
"version": "4.19.1",
|
||||
"description": "AutoRest Modeler Version Four (component)",
|
||||
"directories": {
|
||||
"doc": "docs"
|
||||
|
|
|
@ -110,7 +110,7 @@ export class SecurityProcessor {
|
|||
for (const oai3SecurityRequirement of security) {
|
||||
const names = Object.keys(oai3SecurityRequirement);
|
||||
if (names.length > 1) {
|
||||
throw new Error(
|
||||
this.session.warning(
|
||||
[
|
||||
`Security defines multiple requirements at the same time which is not supported(${names.join(",")}).`,
|
||||
`Did you meant to have multiple authentication options instead? Define each option seperately in your spec:`,
|
||||
|
@ -120,8 +120,11 @@ export class SecurityProcessor {
|
|||
2,
|
||||
),
|
||||
].join("\n"),
|
||||
["MultipleSecurityLayerUnsupported"],
|
||||
);
|
||||
continue;
|
||||
}
|
||||
|
||||
if (names.length === 0) {
|
||||
throw new Error(`Invalid empty security requirement`);
|
||||
}
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
},
|
||||
"homepage": "https://github.com/Azure/autorest#readme",
|
||||
"dependencies": {
|
||||
"@autorest/core": "~3.4.0",
|
||||
"@autorest/core": "~3.4.1",
|
||||
"autorest": "~3.2.0",
|
||||
"source-map-support": "^0.5.19"
|
||||
},
|
||||
|
|
Загрузка…
Ссылка в новой задаче