Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error edge-tts --list-voices #271

Closed
galigaligo opened this issue Oct 19, 2024 · 9 comments
Closed

error edge-tts --list-voices #271

galigaligo opened this issue Oct 19, 2024 · 9 comments

Comments

@galigaligo
Copy link

edge-tts --list-voices
edge-tts --list-voices Traceback (most recent call last): File "D:\soft\miniconda\dabao\lib\runpy.py", line 194, in _run_module_as_main return _run_code(code, main_globals, None, File "D:\soft\miniconda\dabao\lib\runpy.py", line 87, in _run_code exec(code, run_globals) File "D:\soft\miniconda\dabao\Scripts\edge-tts.exe\__main__.py", line 7, in <module> File "D:\soft\miniconda\dabao\lib\site-packages\edge_tts\util.py", line 136, in main asyncio.run(amain()) File "D:\soft\miniconda\dabao\lib\asyncio\runners.py", line 44, in run return loop.run_until_complete(main) File "D:\soft\miniconda\dabao\lib\asyncio\base_events.py", line 616, in run_until_complete return future.result() File "D:\soft\miniconda\dabao\lib\site-packages\edge_tts\util.py", line 118, in amain await _print_voices(proxy=args.proxy) File "D:\soft\miniconda\dabao\lib\site-packages\edge_tts\util.py", line 16, in _print_voices voices = await list_voices(proxy=proxy) File "D:\soft\miniconda\dabao\lib\site-packages\edge_tts\list_voices.py", line 45, in list_voices data = json.loads(await url.text()) File "D:\soft\miniconda\dabao\lib\json\__init__.py", line 357, in loads return _default_decoder.decode(s) File "D:\soft\miniconda\dabao\lib\json\decoder.py", line 337, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "D:\soft\miniconda\dabao\lib\json\decoder.py", line 355, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0) Exception ignored in: <function _ProactorBasePipeTransport.__del__ at 0x000001FD544AD820> Traceback (most recent call last): File "D:\soft\miniconda\dabao\lib\asyncio\proactor_events.py", line 116, in __del__ self.close() File "D:\soft\miniconda\dabao\lib\asyncio\proactor_events.py", line 108, in close self._loop.call_soon(self._call_connection_lost, None) File "D:\soft\miniconda\dabao\lib\asyncio\base_events.py", line 719, in call_soon self._check_closed() File "D:\soft\miniconda\dabao\lib\asyncio\base_events.py", line 508, in _check_closed raise RuntimeError('Event loop is closed') RuntimeError: Event loop is closed

@rany2
Copy link
Owner

rany2 commented Oct 19, 2024

Does updating to 6.1.13 fix it?

@galigaligo
Copy link
Author

I have tested it, but it doesn't work

@einsqing
Copy link

same issue,403,Is there a solution to this?

@einsqing
Copy link

einsqing commented Oct 19, 2024

It's solved. Just modify the user-agent.

"User-Agent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36 Edg/129.0.0.0",

@rany2

@rany2
Copy link
Owner

rany2 commented Oct 19, 2024

@einsqing it's already fixed like this in 6.1.13.

I'm not sure why it didn't work for @galigaligo

@einsqing
Copy link

einsqing commented Oct 19, 2024

@rany2

@einsqing it's already fixed like this in 6.1.13.

I'm not sure why it didn't work for @galigaligo

I tested it but it didn't work in 6.1.13. We need to change the user-agent to fix the issue.
#251 this problem can also be solved at the same time

@rany2
Copy link
Owner

rany2 commented Oct 19, 2024

@einsqing 6.1.13 changes the user agent like this...

@rany2 rany2 closed this as completed Oct 19, 2024
@rany2
Copy link
Owner

rany2 commented Oct 19, 2024

Ah nevermind, I'll fix it now.

rany2 added a commit that referenced this issue Oct 19, 2024
rany2 added a commit that referenced this issue Oct 19, 2024
@rany2
Copy link
Owner

rany2 commented Oct 19, 2024

edge-tts 6.1.14 has been released.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants