Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

unable to run simple app - error : The setup_event_loop method was replaced by get_loop_factory in uvicorn 0.36.0 #1304

Unanswered
rameshiyerv asked this question in Problem
Discussion options

Hey Team!
Really looking forward to use this library for our UI development.

Here is some starting trouble we are facing...

Successfully installed package using conda
image

simple app as shown in the examples
`from reactpy import component, html, run

@component
def APP():
return html.h1("Hello, world!")

run(APP)`

Error while running the app:

File "/home/iyerram/anaconda3/envs/reactpy/lib/python3.14/site-packages/reactpy/backend/_common.py", line 44, in serve_with_uvicorn
server.config.setup_event_loop()
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
File "/home/iyerram/anaconda3/envs/reactpy/lib/python3.14/site-packages/uvicorn/config.py", line 479, in setup_event_loop
raise AttributeError(
...<3 lines>...
)
AttributeError: The setup_event_loop method was replaced by get_loop_factory in uvicorn 0.36.0.

full trace
image

environment
building using vscode, WSL on a win 11, conda for environment management

You must be logged in to vote

Replies: 1 comment 2 replies

Comment options

Apologies for the late response - ReactPy v2 is in the process of replacing v1 precisely due to dependency issues like this. Version 2 is still in open beta, primarily due to the fact that I want to release it alongside overhauled documentation.

This version can be installed with the following command: pip install reactpy[asgi]==2.0.0b2. Quick-start instructions can be found on the beta docs.

If you wish to remain on v1 for now, then I'd recommend manually downgrading your version of uvicorn.

You must be logged in to vote
2 replies
Comment options

What a great and exsiting major version! Is there any plan about when will v2.0.0 (without beta) release?

Comment options

I don't have a firm timeline for it at the moment. Rewriting the docs is about a month worth of labor. Ultimately it is heavily reliant on my day job not eating all my free time.

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

AltStyle によって変換されたページ (->オリジナル) /