mirror of https://gitlab.com/pamhyr/pamhyr2
Solver: CommandLine: Try fix Windows encoding crash.
parent
ee6b2a94eb
commit
441a064d84
|
|
@ -167,8 +167,10 @@ class CommandLineSolver(AbstractSolver):
|
|||
repertory, "pamhyr-study-description.txt"
|
||||
)
|
||||
|
||||
with open(path, "w+") as f:
|
||||
txt = study.description
|
||||
with open(path, "w+", encoding='utf-8') as f:
|
||||
txt = study.description\
|
||||
.encode()\
|
||||
.decode('utf-8', 'replace')
|
||||
f.write(txt)
|
||||
|
||||
#######
|
||||
|
|
|
|||
Loading…
Reference in New Issue