Skip to content
Snippets Groups Projects
Commit 8e46c4e1 authored by Studer Gabriel's avatar Studer Gabriel
Browse files

set universal_newlines flag in Popen

This enables string encoding in passed streams => stdout and stderr
parent 33e8b86a
No related branches found
No related tags found
No related merge requests found
......@@ -63,7 +63,7 @@ def HBondList(ent, hbplus_bin=None):
full_bin=_LocateHBPlus(hbplus_bin)
temp_d=tempfile.mkdtemp(prefix='hbplus_')
hb_proc=subprocess.Popen(full_bin, shell=True, stdout=subprocess.PIPE,
stdin=subprocess.PIPE)
stdin=subprocess.PIPE, universal_newlines=True)
file_name=os.path.join(temp_d, 'ent.pdb')
io.SaveEntity(ent, file_name)
hb_proc.stdin.write('%s\n' % temp_d)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment