Skip to content

Commit

Permalink
Fixed bug on Windows that treats MSVC banner as error
Browse files Browse the repository at this point in the history
  • Loading branch information
Pebaz committed Dec 21, 2019
1 parent cf8d40a commit fef647a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion nimporter.py
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,10 @@ def compile(cls, module_path, release_mode=False):
if NIM_COMPILE_ERROR in err:
raise NimCompilerException(err)
elif err:
raise Exception(err)
# NOTE(pebaz): On Windows, Nim spits out the MSVC banner to stderr,
# causing `err` to not be None. If it built, ignore the error.
if not build_artifact.exists():
raise Exception(err)
elif NIM_COMPILE_ERROR in out:
raise NimCompilerException(out)

Expand Down

0 comments on commit fef647a

Please sign in to comment.