From 48e3319771023ec88ec8950c874524f6454d80ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20D=C3=A9moulins?= Date: Wed, 30 Oct 2019 23:24:03 +0100 Subject: [PATCH 1/5] Add parameter to support partially succeeded and failed builds Fixes #11556 --- .../resources.resjson/en-US/resources.resjson | 2 ++ Tasks/DownloadPipelineArtifactV2/task.json | 14 ++++++++++++++ Tasks/DownloadPipelineArtifactV2/task.loc.json | 14 ++++++++++++++ 3 files changed, 30 insertions(+) diff --git a/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson b/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson index e3c5a9a79215..a05a2eaf7666 100644 --- a/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson +++ b/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson @@ -18,6 +18,8 @@ "loc.input.help.runId": "The build from which to download the artifacts.", "loc.input.label.tags": "Build Tags", "loc.input.help.tags": "A comma-delimited list of tags. Only builds with these tags will be returned.", + "loc.input.label.minimumBuildStatus": "Minimum build status", + "loc.input.help.minimumBuildStatus": "Only builds with at least this status will be returned.", "loc.input.label.artifact": "Artifact name", "loc.input.help.artifact": "The name of the artifact to download. If left empty, it will download all artifacts associated to the pipeline run.", "loc.input.label.patterns": "Matching patterns", diff --git a/Tasks/DownloadPipelineArtifactV2/task.json b/Tasks/DownloadPipelineArtifactV2/task.json index 26f1d5b6d2b4..887cbaec19a2 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.json +++ b/Tasks/DownloadPipelineArtifactV2/task.json @@ -128,6 +128,20 @@ "required": false, "helpMarkDown": "A comma-delimited list of tags. Only builds with these tags will be returned." }, + { + "name": "minimumBuildStatus", + "type": "pickList", + "label": "Minimum build status", + "defaultValue": "succeeded", + "visibleRule": "source == specific && runVersion != specific", + "required": false, + "options": { + "succeeded": "Succeeded", + "partiallySucceeded": "Partially succeeded", + "failed": "Failed" + }, + "helpMarkDown": "Only builds with at least this status will be returned." + }, { "name": "artifact", "aliases": [ diff --git a/Tasks/DownloadPipelineArtifactV2/task.loc.json b/Tasks/DownloadPipelineArtifactV2/task.loc.json index a84e32daa16a..b40fd7936072 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.loc.json +++ b/Tasks/DownloadPipelineArtifactV2/task.loc.json @@ -129,6 +129,20 @@ "helpMarkDown": "ms-resource:loc.input.help.tags" }, { + "name": "minimumBuildStatus", + "type": "pickList", + "label": "ms-resource:loc.input.label.minimumBuildStatus", + "defaultValue": "succeeded", + "visibleRule": "source == specific && runVersion != specific", + "required": false, + "options": { + "succeeded": "Succeeded", + "partiallySucceeded": "Partially succeeded", + "failed": "Failed" + }, + "helpMarkDown": "ms-resource:loc.input.help.minimumBuildStatus" + }, +{ "name": "artifact", "aliases": [ "artifactName" From ab66ecdbb684244bcdcd11c7e83dea13f9e273d6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20D=C3=A9moulins?= Date: Thu, 31 Oct 2019 07:41:33 +0100 Subject: [PATCH 2/5] Minor version update --- Tasks/DownloadPipelineArtifactV2/task.json | 2 +- Tasks/DownloadPipelineArtifactV2/task.loc.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Tasks/DownloadPipelineArtifactV2/task.json b/Tasks/DownloadPipelineArtifactV2/task.json index 887cbaec19a2..3c5f7c21a81b 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.json +++ b/Tasks/DownloadPipelineArtifactV2/task.json @@ -9,7 +9,7 @@ "author": "Microsoft Corporation", "version": { "Major": 2, - "Minor": 0, + "Minor": 1, "Patch": 0 }, "groups": [], diff --git a/Tasks/DownloadPipelineArtifactV2/task.loc.json b/Tasks/DownloadPipelineArtifactV2/task.loc.json index b40fd7936072..f47fa059908c 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.loc.json +++ b/Tasks/DownloadPipelineArtifactV2/task.loc.json @@ -9,7 +9,7 @@ "author": "Microsoft Corporation", "version": { "Major": 2, - "Minor": 0, + "Minor": 1, "Patch": 0 }, "groups": [], From 0104c92da340c80ed8f9a4a208034e065f330f10 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20D=C3=A9moulins?= Date: Sat, 2 Nov 2019 16:52:36 +0100 Subject: [PATCH 3/5] Replace minimumBuildStatus parameter by allowPartiallySucceededBuilds and allowFailedBuilds --- .../resources.resjson/en-US/resources.resjson | 6 +++-- Tasks/DownloadPipelineArtifactV2/task.json | 24 ++++++++++------- .../DownloadPipelineArtifactV2/task.loc.json | 26 +++++++++++-------- 3 files changed, 33 insertions(+), 23 deletions(-) diff --git a/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson b/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson index a05a2eaf7666..de0b01766142 100644 --- a/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson +++ b/Tasks/DownloadPipelineArtifactV2/Strings/resources.resjson/en-US/resources.resjson @@ -18,8 +18,10 @@ "loc.input.help.runId": "The build from which to download the artifacts.", "loc.input.label.tags": "Build Tags", "loc.input.help.tags": "A comma-delimited list of tags. Only builds with these tags will be returned.", - "loc.input.label.minimumBuildStatus": "Minimum build status", - "loc.input.help.minimumBuildStatus": "Only builds with at least this status will be returned.", + "loc.input.label.allowPartiallySucceededBuilds": "Download artifacts from partially succeeded builds.", + "loc.input.help.allowPartiallySucceededBuilds": "If checked, this build task will try to download artifacts whether the build is succeeded or partially succeeded.", + "loc.input.label.allowFailedBuilds": "Download artifacts from failed builds.", + "loc.input.help.allowFailedBuilds": "If checked, this build task will try to download artifacts whether the build is succeeded or failed.", "loc.input.label.artifact": "Artifact name", "loc.input.help.artifact": "The name of the artifact to download. If left empty, it will download all artifacts associated to the pipeline run.", "loc.input.label.patterns": "Matching patterns", diff --git a/Tasks/DownloadPipelineArtifactV2/task.json b/Tasks/DownloadPipelineArtifactV2/task.json index 3c5f7c21a81b..99ead5812fe4 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.json +++ b/Tasks/DownloadPipelineArtifactV2/task.json @@ -129,18 +129,22 @@ "helpMarkDown": "A comma-delimited list of tags. Only builds with these tags will be returned." }, { - "name": "minimumBuildStatus", - "type": "pickList", - "label": "Minimum build status", - "defaultValue": "succeeded", + "name": "allowPartiallySucceededBuilds", + "type": "boolean", + "label": "Download artifacts from partially succeeded builds.", + "defaultValue": "false", "visibleRule": "source == specific && runVersion != specific", "required": false, - "options": { - "succeeded": "Succeeded", - "partiallySucceeded": "Partially succeeded", - "failed": "Failed" - }, - "helpMarkDown": "Only builds with at least this status will be returned." + "helpMarkDown": "If checked, this build task will try to download artifacts whether the build is succeeded or partially succeeded." + }, + { + "name": "allowFailedBuilds", + "type": "boolean", + "label": "Download artifacts from failed builds.", + "defaultValue": "false", + "visibleRule": "source == specific && runVersion != specific", + "required": false, + "helpMarkDown": "If checked, this build task will try to download artifacts whether the build is succeeded or failed." }, { "name": "artifact", diff --git a/Tasks/DownloadPipelineArtifactV2/task.loc.json b/Tasks/DownloadPipelineArtifactV2/task.loc.json index f47fa059908c..0ec0ffa25652 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.loc.json +++ b/Tasks/DownloadPipelineArtifactV2/task.loc.json @@ -129,20 +129,24 @@ "helpMarkDown": "ms-resource:loc.input.help.tags" }, { - "name": "minimumBuildStatus", - "type": "pickList", - "label": "ms-resource:loc.input.label.minimumBuildStatus", - "defaultValue": "succeeded", + "name": "allowPartiallySucceededBuilds", + "type": "boolean", + "label": "ms-resource:loc.input.label.allowPartiallySucceededBuilds", + "defaultValue": "false", "visibleRule": "source == specific && runVersion != specific", "required": false, - "options": { - "succeeded": "Succeeded", - "partiallySucceeded": "Partially succeeded", - "failed": "Failed" - }, - "helpMarkDown": "ms-resource:loc.input.help.minimumBuildStatus" + "helpMarkDown": "ms-resource:loc.input.help.allowPartiallySucceededBuilds" }, -{ + { + "name": "allowFailedBuilds", + "type": "boolean", + "label": "ms-resource:loc.input.label.allowFailedBuilds", + "defaultValue": "false", + "visibleRule": "source == specific && runVersion != specific", + "required": false, + "helpMarkDown": "ms-resource:loc.input.help.allowFailedBuilds" + }, + { "name": "artifact", "aliases": [ "artifactName" From f0d730fe137ba829cc9bf0ae14e478af871faa77 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20D=C3=A9moulins?= Date: Mon, 4 Nov 2019 22:04:36 +0100 Subject: [PATCH 4/5] Increment minor version --- Tasks/DownloadPipelineArtifactV2/task.json | 2 +- Tasks/DownloadPipelineArtifactV2/task.loc.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Tasks/DownloadPipelineArtifactV2/task.json b/Tasks/DownloadPipelineArtifactV2/task.json index bd1bc15faa1f..166213bc5358 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.json +++ b/Tasks/DownloadPipelineArtifactV2/task.json @@ -9,7 +9,7 @@ "author": "Microsoft Corporation", "version": { "Major": 2, - "Minor": 1, + "Minor": 2, "Patch": 0 }, "groups": [], diff --git a/Tasks/DownloadPipelineArtifactV2/task.loc.json b/Tasks/DownloadPipelineArtifactV2/task.loc.json index 1f7534e54f08..58f37b300385 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.loc.json +++ b/Tasks/DownloadPipelineArtifactV2/task.loc.json @@ -9,7 +9,7 @@ "author": "Microsoft Corporation", "version": { "Major": 2, - "Minor": 1, + "Minor": 2, "Patch": 0 }, "groups": [], From 21ef88c120cf790cf0aa9b671d5d972c67db3b2d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20D=C3=A9moulins?= Date: Fri, 22 Nov 2019 07:58:10 +0100 Subject: [PATCH 5/5] Update min agent version --- Tasks/DownloadPipelineArtifactV2/task.json | 2 +- Tasks/DownloadPipelineArtifactV2/task.loc.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Tasks/DownloadPipelineArtifactV2/task.json b/Tasks/DownloadPipelineArtifactV2/task.json index a1057f30b216..4086a2e61713 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.json +++ b/Tasks/DownloadPipelineArtifactV2/task.json @@ -15,7 +15,7 @@ "groups": [], "demands": [], "preview": false, - "minimumAgentVersion": "2.159.2", + "minimumAgentVersion": "2.161.0", "inputs": [ { "name": "source", diff --git a/Tasks/DownloadPipelineArtifactV2/task.loc.json b/Tasks/DownloadPipelineArtifactV2/task.loc.json index 58f37b300385..da57e40f23b0 100644 --- a/Tasks/DownloadPipelineArtifactV2/task.loc.json +++ b/Tasks/DownloadPipelineArtifactV2/task.loc.json @@ -15,7 +15,7 @@ "groups": [], "demands": [], "preview": false, - "minimumAgentVersion": "2.159.2", + "minimumAgentVersion": "2.161.0", "inputs": [ { "name": "source",