Python calls antiword to convert doc file and returns garbled code.

problem description

using python to call antiword to convert doc to txt, it is found that the returned value is garbled, and using antiword on powershell is also garbled. It is no problem to call on git bash

the environmental background of the problems and what methods you have tried

Environment: windows platform, py3.6
tried to change the locale, and tried the-m parameter of antiword, but it didn"t work.

related codes

/ / Please paste the code text below (do not replace the code with pictures)

pipe = subprocess.Popen(
        ["antiword", filename],
        stdout=subprocess.PIPE, 
        stderr=subprocess.PIPE  )

stdout, stderr = pipe.communicate()
return stdout

Oct.15,2021
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1b329e8-2be12.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1b329e8-2be12.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?