Error in exec/local.py run method when OSError is thrown #172
Labels
No labels
bugfix
cleanup
discussion
documentation
doing
done
feature
improvement
packaging
Stale
testing
TODO
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
ungleich-public/cdist#172
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Created by: darko-poljak
line 197 catches OSError and line 198 tries to raise cdist.Error:
raise cdist.Error(" ".join(*args) + ": " + error.args[1])args is not defined in this scope.
Even if this is changed to error.args error is for join: it expects one argument (sequence),
but *args unpacks list/tuple.
So this should be
raise cdist.Error(" ".join((str(x) for x in error.args)) + ": " + error.args[1])(error.args tuple contains int too).
Or the intention was actually this?
raise cdist.Error(str(error.args[0]) + ": " + error.args[1])Created by: darko-poljak
Code is merged with ungleich/master.
Created by: telmich
The idea was to pass on the error to the user - does that help?