Replies: 3 comments 6 replies
-
Honestly, I don't even know of a sensible way for Python to restart itself. |
Beta Was this translation helpful? Give feedback.
2 replies
-
Is there any solution for this problem? |
Beta Was this translation helpful? Give feedback.
0 replies
-
Maybe something like the following, with the help of if hasattr(sys, 'frozen'):
subprocess.Popen(sys.executable)
sys.exit(0) On windows this works without |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
What's best practice for restarting a onefile-built app in a cross-platform way?
Background: My pyside2-based app uses a python plugin system (pluginlib). When plugins are removed, I'd like to be able to restart the app, to remove unused modules from the python interpreter.
Thanks for any tips you can pass on,
James.
Beta Was this translation helpful? Give feedback.
All reactions