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

Create a proof-of-concept for fast cpu_bound with lazy import #4471

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

falkoschindler
Copy link
Contributor

This PR is a proof-of-concept for faster multiprocessing by lazily filling sys.modules with dummy modules if NiceGUI is already running. It is related to and inspired by the following discussions:

Note: We don't need to move run.py in a separate module as originally planned because nicegui is now cheap to import in subprocesses.

There are still import problems when running with reload=True and exceptions when stopping the app with Ctrl-C.

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

Successfully merging this pull request may close these issues.

1 participant