actions / download-artifact

MIT License
1.44k stars 495 forks source link

[bug] Error message for downloading an artifact with the same name as an existing directory should be more clear #345

Open NoraCodes opened 3 months ago

NoraCodes commented 3 months ago

What happened?

I went from having a working artifact download to a failing one because I renamed a directory. The error message was unclear.

What did you expect to happen?

The error message should say something like, "Could not extract artifact because a file (or directory) exists with the same name.", or, at worst, "Failed to write to local filesystem." The specific working of "download failed" is very confusing.

How can we reproduce it?

Have an artifact with a single file called foo. actions/download-artifact@v4 that artifact into a CI state that already has a directory called foo. Observe a terrible error message:

Error: Unable to download artifact(s): Unable to download and extract artifact: Artifact download failed after 5 retries.

Anything else we need to know?

No response

What version of the action are you using?

v4

What are your runner environments?

linux

Are you on GitHub Enterprise Server? If so, what version?

No response