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
Custom scripts fail at failing #169
Comments
@jtishey thanks for raising this, yes you are correct. Would you like to PR? Tbot |
OK cool. Yeah, I'll open a PR for this. Thanks! |
jtishey
pushed a commit
to jtishey/netpalm
that referenced
this issue
Oct 29, 2021
jtishey
pushed a commit
to jtishey/netpalm
that referenced
this issue
Oct 29, 2021
PR #170 submitted. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
It seems like when a script runs into an exception, it gets caught by
s_exec
innetpalm/backend/plugins/calls/scriptrunner/script.py
and returns the exception string to thescript_exec
function, which then has no way to know it failed. This makes scripts always be reported as successful. Would it be better to either remove the try/except ins_exec
or maybe have it re-raise the exception or something? Am I just missing something here?Modified "hello_world" script to fail and raise an exception:
Current result:
Modified scriptrunner/script.py function:
Result with modified s_exec():
The text was updated successfully, but these errors were encountered: