We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9a2fe77 commit 943c503Copy full SHA for 943c503
src/utils/filesystem.py
@@ -19,10 +19,11 @@
19
20
def get_application_path():
21
if sys.platform == 'win32':
22
- if getattr(sys, 'frozen', True):
23
- return os.path.abspath(os.path.join(os.path.dirname(__file__), os.path.pardir, os.path.pardir))
+ if getattr(sys, 'frozen', False):
+ return os.path.dirname(sys.executable)
24
+
25
+ return os.path.abspath(os.path.dirname(os.path.dirname(os.path.dirname(sys.executable))))
26
- return os.path.dirname(os.path.abspath(sys.executable))
27
elif sys.platform == 'linux':
28
is_in_exe = getattr(sys, 'frozen', False)
29
if is_in_exe:
0 commit comments