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

Better errors #346

Open
adswa opened this issue Feb 28, 2023 · 0 comments
Open

Better errors #346

adswa opened this issue Feb 28, 2023 · 0 comments

Comments

@adswa
Copy link
Member

adswa commented Feb 28, 2023

This is what I see when attempting a file-level extraction of metadata on an untracked file:

(handbook) adina@muninn in /tmp/ds1 on git:master!
❱ datalad meta-extract -d . metalad_core newfile       
[ERROR  ] error getting status for file: /tmp/ds1/newfile:

We could probably error out a bit prettier here.

Edit: Actually, I found a variety of errors that could be proper error results. They currently all just raise, and don't perform any structured reporting:

(handbook) adina@muninn in /tmp/ds1 on git:master!
❱ datalad meta-extract -d . metalad_example_file newfile 
[ERROR  ] file not tracked: /tmp/ds1/newfile 
(handbook) adina@muninn in /tmp/ds1 on git:master!
❱ datalad meta-extract -d . metalad_example_dataset newfile 
[ERROR  ] A file-level metadata-extraction was attempted, but the specified extractor (metalad_example_dataset) is not a file-level extractor. 
@adswa adswa changed the title Better error when extracting untracked files Better errors Feb 28, 2023
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

No branches or pull requests

1 participant