Skip to content

Commit

Permalink
Remove astpretty as a dependency of pyflamegpu
Browse files Browse the repository at this point in the history
astpretty is only used for prettyprint debugging in codegen testing - it is not a pyflamegpu dependency.

This commit also makes it an optional test_codegen.py dependency (but installs it in the test venv by default)

Closses #1164
  • Loading branch information
ptheywood committed Dec 14, 2023
1 parent 3c7138c commit da93276
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/python/codegen/test_codegen.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
try:
import astpretty
except ImportError:
pass
print("Install astpretty if ast tree printing required for test debugging")


DEBUG_OUT = True
EXCEPTION_MSG_CHECKING = True
Expand Down Expand Up @@ -596,7 +597,7 @@ def _checkExpected(self, source, expected):
try:
astpretty.pprint(tree)
except NameError:
print("Install astpretty if debugging required")
pass
code = pyflamegpu.codegen.codegen(tree)
# remove new lines
code = code.strip()
Expand Down

0 comments on commit da93276

Please sign in to comment.