__init__.py
5.63 KB
-
Fix an UnboundLocalError if a compiler fails. · c0937f1a
Depending on where an exception is raised inside a compiler's `execute_command`, the `stdout` variable may not be assigned. In this case, the finally handler would fail with an `UnboundLocalError`, hiding the true cause of the exception. This change adds a new variable, `stdout_name`, which is populated once we've actually created the file. After this, the `CompilerError` is successfully raised with the contents of the true error.
David Trowbridge committed