Skip to content

Commit cd41c7b

Browse files
committed
Fixes encoding problem on Windows systems, with minimal changes to existing code.
1 parent a2d1a1f commit cd41c7b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

bin/util.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,8 @@ def read_markdown(parser, path):
117117
# Parse Markdown.
118118
cmd = 'ruby {0}'.format(parser)
119119
p = Popen(cmd, shell=True, stdin=PIPE, stdout=PIPE,
120-
close_fds=True, universal_newlines=True)
121-
body = str(body.encode('utf-8'))
120+
close_fds=True, universal_newlines=True, encoding='utf-8')
121+
122122
stdout_data, stderr_data = p.communicate(body)
123123
doc = json.loads(stdout_data)
124124

0 commit comments

Comments
 (0)