Skip to content

Commit

Permalink
Make BypassStdoutInterpreter compatible with EmPy 4.x
Browse files Browse the repository at this point in the history
  • Loading branch information
cottsay committed Sep 6, 2024
1 parent 090e650 commit 414beda
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions colcon_core/shell/template/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,12 @@ def expand_template(template_path, destination_path, data):
class BypassStdoutInterpreter(Interpreter):
"""Interpreter for EmPy which keeps `stdout` unchanged."""

def installProxy(self): # noqa: D102 N802
def installProxy(self, *args, **kwargs): # noqa: D102 N802
# avoid replacing stdout with ProxyFile
pass
# in EmPy 3.x, this function performed in-place modification.
# in EmPy 4.x, it is passed the output stream and is expected to
# return the output stream.
return next(iter(args), None)


cached_tokens = {}
Expand Down

0 comments on commit 414beda

Please sign in to comment.