[PyQt] Finding the app folder under pyqtdeploy
davecortesi at gmail.com
Tue Aug 5 19:03:20 BST 2014
Looking ahead while coding an app that I expect will use pyqtdeploy. An app
bundled by pyinstaller, and I think also by cxfreeze, can know if it is
running bundled and discover the folder path of the app with code like the
> if hasattr(sys, 'frozen'): # running bundled
> my_folder = os.path.dirname(sys.executable)
> else: # run from command line or IDE
> my_folder = os.path.dirname(__file__)
Looking at the pyqtdeploy doc I see no similar advice, except for this
sentence in ,
> Every deployed application is able to import the pyqtdeploy module.
> This enables the application to determine if it is running as a
> deployed application...
It's not clear to me what the "am I bundled" test should consist of --
perhaps a try/except block around "import pyqtdeploy"?
Thanks for any advice,
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the PyQt