Skip to content

Commit

Permalink
Succeeding deprecated tasks with issues (#19458)
Browse files Browse the repository at this point in the history
* Suceeding deprecated tasks with issues

* Bumped task versions

* Matching _generated files to task files

* Matching NuGetRestoreV1 _generated files to task files

---------

Co-authored-by: Abby Powell (from Dev Box) <[email protected]>
  • Loading branch information
amp-powell and Abby Powell (from Dev Box) authored Jan 24, 2024
1 parent 2eaf669 commit 47fb734
Show file tree
Hide file tree
Showing 29 changed files with 49 additions and 73 deletions.
2 changes: 1 addition & 1 deletion Tasks/DownloadPackageV0/download.ts
Original file line number Diff line number Diff line change
Expand Up @@ -238,5 +238,5 @@ export async function unzip(zipLocation: string, unzipLocation: string): Promise
}

main()
.then(() => tl.setResult(tl.TaskResult.Succeeded, ""))
.then(() => tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask")))
.catch((error) => tl.setResult(tl.TaskResult.Failed, error));
2 changes: 1 addition & 1 deletion Tasks/DownloadPackageV0/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "ms-vscs-rm",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"demands": [],
Expand Down
2 changes: 1 addition & 1 deletion Tasks/DownloadPackageV0/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "ms-vscs-rm",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"demands": [],
Expand Down
2 changes: 1 addition & 1 deletion Tasks/NuGetInstallerV0/nugetinstaller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ async function main(): Promise<void> {
throw new Error(tl.loc("DeprecatedTask"));
}

tl.setResult(tl.TaskResult.Succeeded, tl.loc("PackagesInstalledSuccessfully"));
tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask"));

} catch (err) {
tl.error(err);
Expand Down
2 changes: 1 addition & 1 deletion Tasks/NuGetInstallerV0/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down
2 changes: 1 addition & 1 deletion Tasks/NuGetInstallerV0/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down
2 changes: 1 addition & 1 deletion Tasks/NuGetRestoreV1/nugetinstaller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ async function main(): Promise<void> {

isNugetOrgBehaviorWarn
? tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("Warning_IncludeNuGetOrgEnabled"))
: tl.setResult(tl.TaskResult.Succeeded, tl.loc("PackagesInstalledSuccessfully"));
: tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask"));


} catch (err) {
Expand Down
2 changes: 1 addition & 1 deletion Tasks/NuGetRestoreV1/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 1,
"Minor": 232,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down
2 changes: 1 addition & 1 deletion Tasks/NuGetRestoreV1/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 1,
"Minor": 232,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down
4 changes: 2 additions & 2 deletions _generated/DownloadPackageV0.versionmap.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Default|0.233.0
Node20_229_1|0.233.1
Default|0.234.0
Node20_229_1|0.234.1
2 changes: 1 addition & 1 deletion _generated/DownloadPackageV0/download.ts
Original file line number Diff line number Diff line change
Expand Up @@ -234,5 +234,5 @@ export async function unzip(zipLocation: string, unzipLocation: string): Promise
}

main()
.then(() => tl.setResult(tl.TaskResult.Succeeded, ""))
.then(() => tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask")))
.catch((error) => tl.setResult(tl.TaskResult.Failed, error));
6 changes: 3 additions & 3 deletions _generated/DownloadPackageV0/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "ms-vscs-rm",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"demands": [],
Expand Down Expand Up @@ -116,7 +116,7 @@
"DeprecatedTask": "This task is deprecated. Please switch to using DownloadPackage@1 https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/download-package-v1"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
6 changes: 3 additions & 3 deletions _generated/DownloadPackageV0/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "ms-vscs-rm",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"demands": [],
Expand Down Expand Up @@ -116,7 +116,7 @@
"DeprecatedTask": "ms-resource:loc.messages.DeprecatedTask"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
2 changes: 1 addition & 1 deletion _generated/DownloadPackageV0_Node20/download.ts
Original file line number Diff line number Diff line change
Expand Up @@ -234,5 +234,5 @@ export async function unzip(zipLocation: string, unzipLocation: string): Promise
}

main()
.then(() => tl.setResult(tl.TaskResult.Succeeded, ""))
.then(() => tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask")))
.catch((error) => tl.setResult(tl.TaskResult.Failed, error));
6 changes: 3 additions & 3 deletions _generated/DownloadPackageV0_Node20/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "ms-vscs-rm",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 1
},
"demands": [],
Expand Down Expand Up @@ -120,7 +120,7 @@
"DeprecatedTask": "This task is deprecated. Please switch to using DownloadPackage@1 https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/download-package-v1"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
6 changes: 3 additions & 3 deletions _generated/DownloadPackageV0_Node20/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "ms-vscs-rm",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 1
},
"demands": [],
Expand Down Expand Up @@ -120,7 +120,7 @@
"DeprecatedTask": "ms-resource:loc.messages.DeprecatedTask"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
4 changes: 2 additions & 2 deletions _generated/NuGetInstallerV0.versionmap.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Default|0.233.0
Node20_229_1|0.233.1
Default|0.234.0
Node20_229_1|0.234.1
2 changes: 1 addition & 1 deletion _generated/NuGetInstallerV0/nugetinstaller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ async function main(): Promise<void> {
throw new Error(tl.loc("DeprecatedTask"));
}

tl.setResult(tl.TaskResult.Succeeded, tl.loc("PackagesInstalledSuccessfully"));
tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask"));

} catch (err) {
tl.error(err);
Expand Down
6 changes: 3 additions & 3 deletions _generated/NuGetInstallerV0/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down Expand Up @@ -149,7 +149,7 @@
"DeprecatedTask": "This task is deprecated. Please switch to using NuGetCommand@2's 'restore' or 'custom' option https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/nuget-command-v2"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
6 changes: 3 additions & 3 deletions _generated/NuGetInstallerV0/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down Expand Up @@ -149,7 +149,7 @@
"DeprecatedTask": "ms-resource:loc.messages.DeprecatedTask"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
2 changes: 1 addition & 1 deletion _generated/NuGetInstallerV0_Node20/nugetinstaller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ async function main(): Promise<void> {
throw new Error(tl.loc("DeprecatedTask"));
}

tl.setResult(tl.TaskResult.Succeeded, tl.loc("PackagesInstalledSuccessfully"));
tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask"));

} catch (err) {
tl.error(err);
Expand Down
6 changes: 3 additions & 3 deletions _generated/NuGetInstallerV0_Node20/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 1
},
"runsOn": [
Expand Down Expand Up @@ -153,7 +153,7 @@
"DeprecatedTask": "This task is deprecated. Please switch to using NuGetCommand@2's 'restore' or 'custom' option https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/nuget-command-v2"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
6 changes: 3 additions & 3 deletions _generated/NuGetInstallerV0_Node20/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 233,
"Minor": 234,
"Patch": 1
},
"runsOn": [
Expand Down Expand Up @@ -153,7 +153,7 @@
"DeprecatedTask": "ms-resource:loc.messages.DeprecatedTask"
},
"_buildConfigMapping": {
"Default": "0.233.0",
"Node20_229_1": "0.233.1"
"Default": "0.234.0",
"Node20_229_1": "0.234.1"
}
}
2 changes: 1 addition & 1 deletion _generated/NuGetRestoreV1/nugetinstaller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ async function main(): Promise<void> {

isNugetOrgBehaviorWarn
? tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("Warning_IncludeNuGetOrgEnabled"))
: tl.setResult(tl.TaskResult.Succeeded, tl.loc("PackagesInstalledSuccessfully"));
: tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask"));


} catch (err) {
Expand Down
6 changes: 1 addition & 5 deletions _generated/NuGetRestoreV1/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 1,
"Minor": 232,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down Expand Up @@ -169,9 +169,5 @@
"Warning_IncludeNuGetOrgEnabled": "IncludeNugetOrg is currently enabled for this task. To resolve this warning, edit your build task and set 'includeNuGetOrg' to 'false' or deselect 'Use packages from NuGet.org'.",
"Error_IncludeNuGetOrgEnabled": "Packages failed to restore. Edit your build task and set 'includeNuGetOrg' to 'false' or deselect 'Use packages from NuGet.org'.",
"DeprecatedTask": "This task is deprecated. Please switch to using NuGetCommand@2's 'restore' option https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/nuget-command-v2"
},
"_buildConfigMapping": {
"Default": "1.232.0",
"Node20_229_1": "1.232.1"
}
}
6 changes: 1 addition & 5 deletions _generated/NuGetRestoreV1/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 1,
"Minor": 232,
"Minor": 234,
"Patch": 0
},
"runsOn": [
Expand Down Expand Up @@ -169,9 +169,5 @@
"Warning_IncludeNuGetOrgEnabled": "ms-resource:loc.messages.Warning_IncludeNuGetOrgEnabled",
"Error_IncludeNuGetOrgEnabled": "ms-resource:loc.messages.Error_IncludeNuGetOrgEnabled",
"DeprecatedTask": "ms-resource:loc.messages.DeprecatedTask"
},
"_buildConfigMapping": {
"Default": "1.232.0",
"Node20_229_1": "1.232.1"
}
}
2 changes: 1 addition & 1 deletion _generated/NuGetRestoreV1_Node20/nugetinstaller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -240,7 +240,7 @@ async function main(): Promise<void> {

isNugetOrgBehaviorWarn
? tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("Warning_IncludeNuGetOrgEnabled"))
: tl.setResult(tl.TaskResult.Succeeded, tl.loc("PackagesInstalledSuccessfully"));
: tl.setResult(tl.TaskResult.SucceededWithIssues, tl.loc("DeprecatedTask"));


} catch (err) {
Expand Down
12 changes: 2 additions & 10 deletions _generated/NuGetRestoreV1_Node20/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"author": "Microsoft Corporation",
"version": {
"Major": 1,
"Minor": 232,
"Patch": 1
"Minor": 234,
"Patch": 0
},
"runsOn": [
"Agent",
Expand Down Expand Up @@ -129,10 +129,6 @@
"Node16": {
"target": "nugetinstaller.js",
"argumentFormat": ""
},
"Node20_1": {
"target": "nugetinstaller.js",
"argumentFormat": ""
}
},
"messages": {
Expand Down Expand Up @@ -173,9 +169,5 @@
"Warning_IncludeNuGetOrgEnabled": "IncludeNugetOrg is currently enabled for this task. To resolve this warning, edit your build task and set 'includeNuGetOrg' to 'false' or deselect 'Use packages from NuGet.org'.",
"Error_IncludeNuGetOrgEnabled": "Packages failed to restore. Edit your build task and set 'includeNuGetOrg' to 'false' or deselect 'Use packages from NuGet.org'.",
"DeprecatedTask": "This task is deprecated. Please switch to using NuGetCommand@2's 'restore' option https://learn.microsoft.com/en-us/azure/devops/pipelines/tasks/reference/nuget-command-v2"
},
"_buildConfigMapping": {
"Default": "1.232.0",
"Node20_229_1": "1.232.1"
}
}
Loading

0 comments on commit 47fb734

Please sign in to comment.