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

[TVMC] Treat invalid FILE arguments #9213

Merged
merged 1 commit into from Oct 7, 2021
Merged

Conversation

gromero
Copy link
Contributor

@gromero gromero commented Oct 6, 2021

Currently if an invalid FILE argument is passed to 'tvmc run' the user
will catch a traceback because exceptions are not treated, for instance:
$ tvmc run /tmp/nonexistingfile will throw a FileNotFoundError trace.

This commit catches the possible exceptions that can happen when an
invalid FILE argument is used and convert them to better messages for
the user so the invalid FILE can be easily spotted.

Signed-off-by: Gustavo Romero gustavo.romero@linaro.org

Currently if an invalid FILE argument is passed to 'tvmc run' the user
will catch a traceback because exceptions are not treated, for instance:
$ tvmc run /tmp/nonexistingfile will throw a FileNotFoundError trace.

This commit catches the possible exceptions that can happen when an
invalid FILE argument is used and convert them to better messages for
the user so the invalid FILE can be easily spotted.

Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
@gromero
Copy link
Contributor Author

gromero commented Oct 6, 2021

@leandron Just crossed it when wrapping up things for tvcm micro. wdyt? Cheers.

Copy link
Contributor

@leandron leandron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@masahi masahi merged commit d9b93d3 into apache:main Oct 7, 2021
masahi pushed a commit to Laurawly/tvm-1 that referenced this pull request Oct 14, 2021
Currently if an invalid FILE argument is passed to 'tvmc run' the user
will catch a traceback because exceptions are not treated, for instance:
$ tvmc run /tmp/nonexistingfile will throw a FileNotFoundError trace.

This commit catches the possible exceptions that can happen when an
invalid FILE argument is used and convert them to better messages for
the user so the invalid FILE can be easily spotted.

Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
ylc pushed a commit to ylc/tvm that referenced this pull request Jan 7, 2022
Currently if an invalid FILE argument is passed to 'tvmc run' the user
will catch a traceback because exceptions are not treated, for instance:
$ tvmc run /tmp/nonexistingfile will throw a FileNotFoundError trace.

This commit catches the possible exceptions that can happen when an
invalid FILE argument is used and convert them to better messages for
the user so the invalid FILE can be easily spotted.

Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
ylc pushed a commit to ylc/tvm that referenced this pull request Jan 13, 2022
Currently if an invalid FILE argument is passed to 'tvmc run' the user
will catch a traceback because exceptions are not treated, for instance:
$ tvmc run /tmp/nonexistingfile will throw a FileNotFoundError trace.

This commit catches the possible exceptions that can happen when an
invalid FILE argument is used and convert them to better messages for
the user so the invalid FILE can be easily spotted.

Signed-off-by: Gustavo Romero <gustavo.romero@linaro.org>
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 this pull request may close these issues.

None yet

3 participants