I'm getting
Run actions/upload-artifact@v2
With the provided path, there will be 43 files uploaded
events.js:187
throw er; // Unhandled 'error' event
^
Error: EISDIR: illegal operation on a directory, read
Emitted 'error' event on ReadStream instance at:
at internal/fs/streams.js:167:12
at FSReqCallback.wrapper [as oncomplete] (fs.js:470:5) {
errno: -21,
code: 'EISDIR',
syscall: 'read'
}
on macOS-latest when trying to upload a foo.app mac application.
I get same error
Thanks for raising this! I haven't seen this issue before.
Could you create a minimal repo? It would help immensely.
EISDIR is interesting because it looks like it's trying to upload a directory... however we remove any directories before we start the upload. It looks like it's crashing when trying to create a readstream for the directory during upload.
The chunk of code that removes directories is here: https://github.com/actions/upload-artifact/blob/e59920f5cf8316d0f86ce2c7633101dc95b31efe/src/search.ts#L40
If you turn on step debugging you should see a lot more information in terms of what is being considered a directory and what is being removed. More info on turning on step debugging here
Could you create a minimal repo? It would help immensely.
Here's a minimal repo in Rust, attempting to upload the directory target/debug/ as an artifact. See run #1 in 7automaton/macos-eisdir. (There's another instance of this error using the path target/debug, without the extra trailing slash, in run #2 in 7automaton/macos-eisdir.)
This is likely an OS-specific problem with the action, because artifacts are uploaded successfully on ubuntu-latest and windows-latest CI builds.
This is likely an OS-specific problem with the action, because artifacts are uploaded successfully on
ubuntu-latestandwindows-latestCI builds.
I've got this issue with an ubuntu-latest build: https://github.com/BenjaminHae/modern-password-manager/runs/800366157?check_suite_focus=true
Seeing this as well
I've got the same issue apparently. Only on macOS-latest
I got the same issue. My project is on ubuntu-latest.
I made a python venv and upload artifact whole venv directory.
In this situation, I've got the same issue.
When I used @v1, it was working without error
same thing on ubuntu latest with lerna monorepo, when trying to upload the main node_modules directory.
I'm seeing the same thing with a self-hosted Ubuntu runner
had this error on MacOs and changing to v1 of the action fixed it
Can we please stop the "mee too" messages and instead get the issue fixed?
@bnavigator then fix it
@patrickmichalina If I was a typescript developer, I would. Why don't you fix it?
It certainly does not help to have more "mee too" postings.
This issue should be now resolved. The v2 has been updated with the latest changes.
Directories get filtered out before an upload starts, however symlinks that are directories were incorrectly being identified because lstat was being used instead of stat.
Thank you @7automaton for the great minimal repo! 鉂わ笍
It now looks like macOS build artifacts now properly upload, as shown on Actions from 7automaton/macos-eisdir. Thank you for resolving this issue.
Most helpful comment
This issue should be now resolved. The
v2has been updated with the latest changes.Directories get filtered out before an upload starts, however symlinks that are directories were incorrectly being identified because
lstatwas being used instead ofstat.https://stackoverflow.com/questions/32478698/what-is-the-different-between-stat-fstat-and-lstat-functions-in-node-js
Thank you @7automaton for the great minimal repo! 鉂わ笍