pt_PT language fails to download `piper --model pt_PT-tugão-medium`
#21
by
ricardoamaro
- opened
The voice from https://huggingface.co/rhasspy/piper-voices/tree/main/pt/pt_PT/tug%C3%A3o/medium has a special character "ã" which breaks the client when you try to use it.
$ piper --model pt_PT-tugão-medium
Traceback (most recent call last):
File "/home/ricardo/.pyenv/versions/3.10.7/bin/piper", line 8, in <module>
sys.exit(main())
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/site-packages/piper/__main__.py", line 104, in main
ensure_voice_exists(args.model, args.data_dir, args.download_dir, voices_info)
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/site-packages/piper/download.py", line 122, in ensure_voice_exists
with urlopen(file_url) as response, open(
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/urllib/request.py", line 216, in urlopen
return opener.open(url, data, timeout)
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/urllib/request.py", line 519, in open
response = self._open(req, data)
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/urllib/request.py", line 536, in _open
result = self._call_chain(self.handle_open, protocol, protocol +
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/urllib/request.py", line 496, in _call_chain
result = func(*args)
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/urllib/request.py", line 1391, in https_open
return self.do_open(http.client.HTTPSConnection, req,
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/urllib/request.py", line 1348, in do_open
h.request(req.get_method(), req.selector, req.data, headers,
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/http/client.py", line 1282, in request
self._send_request(method, url, body, headers, encode_chunked)
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/http/client.py", line 1293, in _send_request
self.putrequest(method, url, **skips)
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/http/client.py", line 1131, in putrequest
self._output(self._encode_request(request))
File "/home/ricardo/.pyenv/versions/3.10.7/lib/python3.10/http/client.py", line 1211, in _encode_request
return request.encode('ascii')
UnicodeEncodeError: 'ascii' codec can't encode character '\xe3' in position 53: ordinal not in range(128)