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 on Windows 11: "NotImplementedError" in asyncio #184

Open
TheFilipcom4607 opened this issue Aug 27, 2024 · 7 comments
Open

Error on Windows 11: "NotImplementedError" in asyncio #184

TheFilipcom4607 opened this issue Aug 27, 2024 · 7 comments

Comments

@TheFilipcom4607
Copy link

I'm trying to run the project on Windows 11, but I encounter the following error:

Cancelling 0 outstanding tasks
Traceback (most recent call last):
  File "C:\Users\Filip\exo\main.py", line 192, in <module>
    loop.run_until_complete(main())
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.12_3.12.1520.0_x64__qbz5n2kfra8p0\Lib\asyncio\base_events.py", line 687, in run_until_complete
    return future.result()
           ^^^^^^^^^^^^^^^
  File "C:\Users\Filip\exo\main.py", line 177, in main
    loop.add_signal_handler(s, handle_exit)
  File "C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.12_3.12.1520.0_x64__qbz5n2kfra8p0\Lib\asyncio\events.py", line 582, in add_signal_handler
    raise NotImplementedError
NotImplementedError

It seems like loop.add_signal_handler is not supported on Windows. Is there a known workaround for this, or is native Windows support planned?

I can provide more info on request

Thank you!

@TheFilipcom4607 TheFilipcom4607 changed the title Error on Windows 11: NotImplementedError in asyncio Error on Windows 11: "NotImplementedError in" "asyncio" Aug 27, 2024
@TheFilipcom4607 TheFilipcom4607 changed the title Error on Windows 11: "NotImplementedError in" "asyncio" Error on Windows 11: "NotImplementedError" in asyncio Aug 27, 2024
@pTinosq
Copy link

pTinosq commented Aug 27, 2024

Same issue here. Seems like asyncio library is trying to use AbstractEventLoop which seems to be full of "NotImplementedError"s. Also found someone complaining about this issue 4 years ago so it's not looking great for w11 support

@AlexCheema
Copy link
Contributor

AlexCheema commented Aug 27, 2024

Native windows support seems blocked by this, and possibly other stuff as it's untested.
I'm going to leave this open, but unlikely it will be fixed soon as we rely heavily on asyncio. You could try tinkering with alternative libs like trio or uvloop.

If you would like to work on this, I've added a $200 bounty to fix it: #186

@Yazington
Copy link
Contributor

Currently testing on WSL under Ubuntu with Miniconda. Able to download llama3 70B model

@Shivp1413
Copy link

I made changes in main.py file, and now its working for windows as well. But I get following error:
Error: Failed to fetch completions: Error processing prompt (see logs with DEBUG>=2): No module named '_posixshmem'
main.zip

@mrge-org
Copy link

mrge-org commented Oct 9, 2024

I have the same error on my Windows 10 boxes while on my Ubuntu 22.04 box it runs from the first time.
I just did on Windows 10 in my exo environment an experiment with the latest exo changes:
git pull
pip install -e .
exo
and got similar error to the above:

Cancelling 0 outstanding tasks
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "C:\dev\envs\exo\Scripts\exo.exe\__main__.py", line 7, in <module>
  File "C:\Dev\exo\exo\main.py", line 203, in run
    loop.run_until_complete(main())
  File "C:\dev\envs\exo\Lib\asyncio\base_events.py", line 687, in run_until_complete
    return future.result()
           ^^^^^^^^^^^^^^^
  File "C:\Dev\exo\exo\main.py", line 184, in main
    loop.add_signal_handler(s, handle_exit)
  File "C:\dev\envs\exo\Lib\asyncio\events.py", line 582, in add_signal_handler
    raise NotImplementedError
NotImplementedError

@AlexCheema
Copy link
Contributor

I have the same error on my Windows 10 boxes while on my Ubuntu 22.04 box it runs from the first time. I just did on Windows 10 in my exo environment an experiment with the latest exo changes: git pull pip install -e . exo and got similar error to the above:

Cancelling 0 outstanding tasks
Traceback (most recent call last):
  File "<frozen runpy>", line 198, in _run_module_as_main
  File "<frozen runpy>", line 88, in _run_code
  File "C:\dev\envs\exo\Scripts\exo.exe\__main__.py", line 7, in <module>
  File "C:\Dev\exo\exo\main.py", line 203, in run
    loop.run_until_complete(main())
  File "C:\dev\envs\exo\Lib\asyncio\base_events.py", line 687, in run_until_complete
    return future.result()
           ^^^^^^^^^^^^^^^
  File "C:\Dev\exo\exo\main.py", line 184, in main
    loop.add_signal_handler(s, handle_exit)
  File "C:\dev\envs\exo\Lib\asyncio\events.py", line 582, in add_signal_handler
    raise NotImplementedError
NotImplementedError

what version of Python are you running?

@mrge-org
Copy link

(exo) C:\Dev\exo>python --version
Python 3.12.7

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

6 participants