Running in the background #237
-
Is it possible to have the web server running in the background and have other tasks also executing? I want to build a project that has a web interface to do the configuration, but uses GPIO pins and catches actions from physical buttons. This would obviously be a separate loop executing. |
Beta Was this translation helpful? Give feedback.
Answered by
miguelgrinberg
Jun 2, 2024
Replies: 1 comment 6 replies
-
I made it do the thing, but there might be a better way:
|
Beta Was this translation helpful? Give feedback.
6 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is fine, but given that you do not have anything to do in the main asyncio task I would suggest you run one of the two in a background task and the other in the main one.