Skip to content

Commit

Permalink
sanitize error message (#20700)
Browse files Browse the repository at this point in the history
* sanitize error message

* sanitize error message for DockerComposeV0
  • Loading branch information
v-gayatrij authored Dec 3, 2024
1 parent 9c66fd5 commit 298ee40
Show file tree
Hide file tree
Showing 13 changed files with 22 additions and 22 deletions.
2 changes: 1 addition & 1 deletion Tasks/DockerComposeV0/dockercompose.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ if (nopIfNoDockerComposeFile && !tl.exist(dockerFile)) {
tl.setVariable("DockerComposeOutput", resultPaths);
tl.setResult(tl.TaskResult.Succeeded, "");
}, function failure(err) {
tl.setResult(tl.TaskResult.Failed, err.message);
tl.setSanitizedResult(tl.TaskResult.Failed, err.message);
})
.done();
});
Expand Down
2 changes: 1 addition & 1 deletion Tasks/DockerComposeV0/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 247,
"Minor": 249,
"Patch": 0
},
"demands": [],
Expand Down
2 changes: 1 addition & 1 deletion Tasks/DockerComposeV0/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 247,
"Minor": 249,
"Patch": 0
},
"demands": [],
Expand Down
2 changes: 1 addition & 1 deletion Tasks/DockerComposeV1/dockercompose.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ if (nopIfNoDockerComposeFile && !tl.exist(dockerFile)) {
tl.setVariable("DockerComposeOutput", resultPaths);
tl.setResult(tl.TaskResult.Succeeded, "");
}, function failure(err) {
tl.setResult(tl.TaskResult.Failed, err.message);
tl.setSanitizedResult(tl.TaskResult.Failed, err.message);
})
.done();
});
Expand Down
2 changes: 1 addition & 1 deletion Tasks/DockerComposeV1/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 1,
"Minor": 247,
"Minor": 249,
"Patch": 0
},
"demands": [],
Expand Down
2 changes: 1 addition & 1 deletion Tasks/DockerComposeV1/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 1,
"Minor": 247,
"Minor": 249,
"Patch": 0
},
"demands": [],
Expand Down
4 changes: 2 additions & 2 deletions _generated/DockerComposeV0.versionmap.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
Default|0.247.0
Node20_229_2|0.247.1
Default|0.249.0
Node20_229_2|0.249.1
2 changes: 1 addition & 1 deletion _generated/DockerComposeV0/dockercompose.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ if (nopIfNoDockerComposeFile && !tl.exist(dockerFile)) {
tl.setVariable("DockerComposeOutput", resultPaths);
tl.setResult(tl.TaskResult.Succeeded, "");
}, function failure(err) {
tl.setResult(tl.TaskResult.Failed, err.message);
tl.setSanitizedResult(tl.TaskResult.Failed, err.message);
})
.done();
});
Expand Down
6 changes: 3 additions & 3 deletions _generated/DockerComposeV0/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 247,
"Minor": 249,
"Patch": 0
},
"demands": [],
Expand Down Expand Up @@ -362,7 +362,7 @@
"MigrateToDockerComposeV2": "The task is using Docker Compose V1, which is end-of-life and will be removed from Microsoft-hosted agents July 24. Pipelines running on Microsoft-hosted agents should be updated for Docker Compose v2 compatibility e.g. use compatible container names. For guidance on required updates, please refer to the official Docker Compose documentation at https://docs.docker.com/compose/migrate/"
},
"_buildConfigMapping": {
"Default": "0.247.0",
"Node20_229_2": "0.247.1"
"Default": "0.249.0",
"Node20_229_2": "0.249.1"
}
}
6 changes: 3 additions & 3 deletions _generated/DockerComposeV0/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 247,
"Minor": 249,
"Patch": 0
},
"demands": [],
Expand Down Expand Up @@ -362,7 +362,7 @@
"MigrateToDockerComposeV2": "ms-resource:loc.messages.MigrateToDockerComposeV2"
},
"_buildConfigMapping": {
"Default": "0.247.0",
"Node20_229_2": "0.247.1"
"Default": "0.249.0",
"Node20_229_2": "0.249.1"
}
}
2 changes: 1 addition & 1 deletion _generated/DockerComposeV0_Node20/dockercompose.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ if (nopIfNoDockerComposeFile && !tl.exist(dockerFile)) {
tl.setVariable("DockerComposeOutput", resultPaths);
tl.setResult(tl.TaskResult.Succeeded, "");
}, function failure(err) {
tl.setResult(tl.TaskResult.Failed, err.message);
tl.setSanitizedResult(tl.TaskResult.Failed, err.message);
})
.done();
});
Expand Down
6 changes: 3 additions & 3 deletions _generated/DockerComposeV0_Node20/task.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 247,
"Minor": 249,
"Patch": 1
},
"demands": [],
Expand Down Expand Up @@ -366,7 +366,7 @@
"MigrateToDockerComposeV2": "The task is using Docker Compose V1, which is end-of-life and will be removed from Microsoft-hosted agents July 24. Pipelines running on Microsoft-hosted agents should be updated for Docker Compose v2 compatibility e.g. use compatible container names. For guidance on required updates, please refer to the official Docker Compose documentation at https://docs.docker.com/compose/migrate/"
},
"_buildConfigMapping": {
"Default": "0.247.0",
"Node20_229_2": "0.247.1"
"Default": "0.249.0",
"Node20_229_2": "0.249.1"
}
}
6 changes: 3 additions & 3 deletions _generated/DockerComposeV0_Node20/task.loc.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"author": "Microsoft Corporation",
"version": {
"Major": 0,
"Minor": 247,
"Minor": 249,
"Patch": 1
},
"demands": [],
Expand Down Expand Up @@ -366,7 +366,7 @@
"MigrateToDockerComposeV2": "ms-resource:loc.messages.MigrateToDockerComposeV2"
},
"_buildConfigMapping": {
"Default": "0.247.0",
"Node20_229_2": "0.247.1"
"Default": "0.249.0",
"Node20_229_2": "0.249.1"
}
}

0 comments on commit 298ee40

Please sign in to comment.