You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
TXT文件
Traceback (most recent call last):
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 122, in
run()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 50, in run
translate_doc(doc)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 64, in translate_doc
translate.translate()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Txt.py", line 44, in translate
line = f.readline()
UnicodeDecodeError: 'gbk' codec can't decode byte 0xff in position 0: illegal multibyte sequence
PDF文件
Traceback (most recent call last):
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 122, in
run()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 50, in run
translate_doc(doc)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 64, in translate_doc
translate.translate()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Pdf_PyPDF2.py", line 57, in translate
self.write(line + '\n')
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Pdf_PyPDF2.py", line 127, in write
f.write(content)
UnicodeEncodeError: 'gbk' codec can't encode character '\u2122' in position 672: illegal multibyte sequence
docx也报错了  ̄□ ̄||
Traceback (most recent call last):
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 1318, in do_open
encode_chunked=req.has_header('Transfer-encoding'))
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1239, in request
self._send_request(method, url, body, headers, encode_chunked)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1285, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1234, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1026, in _send_output
self.send(msg)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 964, in send
self.connect()
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 936, in connect
(self.host,self.port), self.timeout, self.source_address)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\socket.py", line 724, in create_connection
raise err
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\socket.py", line 713, in create_connection
sock.connect(sa)
TimeoutError: [WinError 10060] 由于连接方在一段时间后没有正确答复或连接的主机没有反应,连接尝试失败。
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 122, in
run()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 50, in run
translate_doc(doc)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 64, in translate_doc
translate.translate()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Docx.py", line 53, in translate
trans = baidu_translate(para.text)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\TranslateFunc.py", line 67, in baidu_translate
baidu_response = urllib.request.urlopen(baidu_re)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 223, in urlopen
return opener.open(url, data, timeout)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 526, in open
response = self._open(req, data)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 544, in _open
'_open', req)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 504, in _call_chain
result = func(*args)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 1346, in http_open
return self.do_open(http.client.HTTPConnection, req)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 1320, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [WinError 10060] 由于连接方在一段时间后没有正确答复或连接的主机没有反应,连接尝试失败。>
The text was updated successfully, but these errors were encountered:
TXT文件
Traceback (most recent call last):
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 122, in
run()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 50, in run
translate_doc(doc)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 64, in translate_doc
translate.translate()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Txt.py", line 44, in translate
line = f.readline()
UnicodeDecodeError: 'gbk' codec can't decode byte 0xff in position 0: illegal multibyte sequence
PDF文件
Traceback (most recent call last):
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 122, in
run()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 50, in run
translate_doc(doc)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 64, in translate_doc
translate.translate()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Pdf_PyPDF2.py", line 57, in translate
self.write(line + '\n')
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Pdf_PyPDF2.py", line 127, in write
f.write(content)
UnicodeEncodeError: 'gbk' codec can't encode character '\u2122' in position 672: illegal multibyte sequence
docx也报错了  ̄□ ̄||
Traceback (most recent call last):
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 1318, in do_open
encode_chunked=req.has_header('Transfer-encoding'))
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1239, in request
self._send_request(method, url, body, headers, encode_chunked)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1285, in _send_request
self.endheaders(body, encode_chunked=encode_chunked)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1234, in endheaders
self._send_output(message_body, encode_chunked=encode_chunked)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 1026, in _send_output
self.send(msg)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 964, in send
self.connect()
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\http\client.py", line 936, in connect
(self.host,self.port), self.timeout, self.source_address)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\socket.py", line 724, in create_connection
raise err
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\socket.py", line 713, in create_connection
sock.connect(sa)
TimeoutError: [WinError 10060] 由于连接方在一段时间后没有正确答复或连接的主机没有反应,连接尝试失败。
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 122, in
run()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 50, in run
translate_doc(doc)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\Main.py", line 64, in translate_doc
translate.translate()
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\T_Docx.py", line 53, in translate
trans = baidu_translate(para.text)
File "D:\desktop\TranslateTool-master\src\TranslateTool\TranslateTool\TranslateFunc.py", line 67, in baidu_translate
baidu_response = urllib.request.urlopen(baidu_re)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 223, in urlopen
return opener.open(url, data, timeout)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 526, in open
response = self._open(req, data)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 544, in _open
'_open', req)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 504, in _call_chain
result = func(*args)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 1346, in http_open
return self.do_open(http.client.HTTPConnection, req)
File "C:\Users\cc\AppData\Local\Programs\Python\Python36-32\lib\urllib\request.py", line 1320, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error [WinError 10060] 由于连接方在一段时间后没有正确答复或连接的主机没有反应,连接尝试失败。>
The text was updated successfully, but these errors were encountered: