Files
picard/tagger.py.in
Philipp Wolfer 9393da348c PICARD-2869: Run register_excepthook early
Don't separately catch exceptions around main but rely on the new excepthook.

This prevents the crash dialog to be shown twice for exceptions which
are catched by the exception handler already.
2024-04-29 08:22:11 +02:00

20 lines
447 B
Python

#!/usr/bin/env python3
import os
import sys
sys.path.insert(0, '.')
# This is needed to find resources when using pyinstaller
if getattr(sys, 'frozen', False) and hasattr(sys, '_MEIPASS'):
basedir = getattr(sys, '_MEIPASS', '')
else:
basedir = os.path.dirname(os.path.abspath(__file__))
from picard import register_excepthook
register_excepthook()
from picard.tagger import main
main(os.path.join(basedir, 'locale'), %(autoupdate)s)