From 6069de27db62256f466e89450c744cd5e957d39b Mon Sep 17 00:00:00 2001 From: eggyhead <28715808+eggyhead@users.noreply.github.com> Date: Thu, 18 Jan 2024 04:10:35 +0000 Subject: [PATCH 1/3] updating artifact not found error message to include more information and link to FAQ --- src/internal/find/get-artifact.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/internal/find/get-artifact.ts b/src/internal/find/get-artifact.ts index b19e5d6..a7b9f1b 100644 --- a/src/internal/find/get-artifact.ts +++ b/src/internal/find/get-artifact.ts @@ -49,7 +49,9 @@ export async function getArtifactPublic( if (getArtifactResp.data.artifacts.length === 0) { throw new ArtifactNotFoundError( - `Artifact not found for name: ${artifactName}` + `Artifact not found for name: ${artifactName}\n + Please ensure that your artifact is not expired and the artifact was uploaded using a compatible version of toolkit/upload-artifact.\n + For more information, visit the Github Artifacts FAQ: https://github.com/actions/toolkit/blob/main/packages/artifact/docs/faq.md` ) } From 833668621d33925b46325361075309c4f3ce3254 Mon Sep 17 00:00:00 2001 From: eggyhead <28715808+eggyhead@users.noreply.github.com> Date: Thu, 18 Jan 2024 04:14:39 +0000 Subject: [PATCH 2/3] update message for internal method --- src/internal/find/get-artifact.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/internal/find/get-artifact.ts b/src/internal/find/get-artifact.ts index a7b9f1b..cbc5f13 100644 --- a/src/internal/find/get-artifact.ts +++ b/src/internal/find/get-artifact.ts @@ -91,7 +91,9 @@ export async function getArtifactInternal( if (res.artifacts.length === 0) { throw new ArtifactNotFoundError( - `Artifact not found for name: ${artifactName}` + `Artifact not found for name: ${artifactName}\n + Please ensure that your artifact is not expired and the artifact was uploaded using a compatible version of toolkit/upload-artifact.\n + For more information, visit the Github Artifacts FAQ: https://github.com/actions/toolkit/blob/main/packages/artifact/docs/faq.md` ) } From e5f0fbac50f2acb23fd44b62f1504fd300546875 Mon Sep 17 00:00:00 2001 From: eggyhead <28715808+eggyhead@users.noreply.github.com> Date: Thu, 18 Jan 2024 15:57:21 +0000 Subject: [PATCH 3/3] removing newline and camelcasing GitHub --- src/internal/find/get-artifact.ts | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/internal/find/get-artifact.ts b/src/internal/find/get-artifact.ts index cbc5f13..900f9b8 100644 --- a/src/internal/find/get-artifact.ts +++ b/src/internal/find/get-artifact.ts @@ -49,9 +49,9 @@ export async function getArtifactPublic( if (getArtifactResp.data.artifacts.length === 0) { throw new ArtifactNotFoundError( - `Artifact not found for name: ${artifactName}\n - Please ensure that your artifact is not expired and the artifact was uploaded using a compatible version of toolkit/upload-artifact.\n - For more information, visit the Github Artifacts FAQ: https://github.com/actions/toolkit/blob/main/packages/artifact/docs/faq.md` + `Artifact not found for name: ${artifactName} + Please ensure that your artifact is not expired and the artifact was uploaded using a compatible version of toolkit/upload-artifact. + For more information, visit the GitHub Artifacts FAQ: https://github.com/actions/toolkit/blob/main/packages/artifact/docs/faq.md` ) } @@ -91,9 +91,9 @@ export async function getArtifactInternal( if (res.artifacts.length === 0) { throw new ArtifactNotFoundError( - `Artifact not found for name: ${artifactName}\n - Please ensure that your artifact is not expired and the artifact was uploaded using a compatible version of toolkit/upload-artifact.\n - For more information, visit the Github Artifacts FAQ: https://github.com/actions/toolkit/blob/main/packages/artifact/docs/faq.md` + `Artifact not found for name: ${artifactName} + Please ensure that your artifact is not expired and the artifact was uploaded using a compatible version of toolkit/upload-artifact. + For more information, visit the GitHub Artifacts FAQ: https://github.com/actions/toolkit/blob/main/packages/artifact/docs/faq.md` ) }