Skip to content

Commit

Permalink
Actually fix console separator issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Eric Arellano committed Aug 17, 2018
1 parent d0c83aa commit f4d4a2d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/python/pants/task/console_task.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ def register_options(cls, register):

def __init__(self, *args, **kwargs):
super(ConsoleTask, self).__init__(*args, **kwargs)
self._console_separator = self.get_options().sep.encode('unicode_escape').decode('utf-8')
self._console_separator = self.get_options().sep.encode('ascii').decode('unicode_escape')
if self.get_options().output_file:
try:
self._outstream = safe_open(os.path.abspath(self.get_options().output_file), 'wb')
Expand All @@ -55,7 +55,7 @@ def execute(self):
targets = self.context.targets()
for value in self.console_output(targets) or tuple():
self._outstream.write(value.encode('utf-8'))
self._outstream.write(self._console_separator.encode('utf-8'))
self._outstream.write(self._console_separator.encode('ascii'))
finally:
self._outstream.flush()
if self.get_options().output_file:
Expand Down

0 comments on commit f4d4a2d

Please sign in to comment.