Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Confusing Error Message When File Does Not Exist #1418

Closed
mwilensky768 opened this issue Apr 20, 2021 · 1 comment · Fixed by #1412
Closed

Confusing Error Message When File Does Not Exist #1418

mwilensky768 opened this issue Apr 20, 2021 · 1 comment · Fixed by #1412

Comments

@mwilensky768
Copy link

Which version of the AzCopy was used?

Note: The version is visible when running AzCopy without any argument

10.8.0

Which platform are you using? (ex: Windows, Mac, Linux)

Linux

What command did you run?

Note: Please remove the SAS to avoid exposing your credentials. If you cannot remember the exact command, please retrieve it from the beginning of the log file.

azcopy copy ${file_path_cubes}/ps/data/uvf_cubes/${cube_name} ${FHD_version}/ps/data/uvf_cubes/${cube_name}`

What problem was encountered?

During development, I hadn't properly assigned the cube_name variable used in the command above. Since the source target file did not exist (which was on azure storage), azcopy seemed to assume I was targeting a (nonexistent) directory [or whatever the analogous object is], and issued me the following error message:

failed to perform copy command due to error: cannot use directory as source without --recursive or a trailing wildcard (/*)

rather than telling me the target did not exist in the filesystem. This caused me to spend a large chunk of time chasing the wrong goose when really I just had a hard-to-spot typo that made me target a nonexistent file. An error message that told me the file (or directory) didn't exist would have made this blunder of mine much easier to spot.

How can we reproduce the problem in the simplest way?

Make a file on azure storage, and use azcopy to copy it to your local machine, except use the wrong name for the file on storage.

Have you found a mitigation/solution?

Ignore the unhelpful error message and instead consider alternate possibilities to locate the mistake that I made.

@EvertEt
Copy link

EvertEt commented Feb 22, 2022

Dear @nakulkar-msft , is there an estimated release date of the linked PR?
The new behaviour of zero-item jobs are a success does not match well with an error if the file is not found (which also means 0 copies)

Many thanks already

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants