Release v1.0.14: stop passing match results through Qt signals.

Store worker results on the thread object, defer preview refresh, and log Python errors to crash.log to prevent native Qt crashes after TheTVDB match.

Co-authored-by: Cursor <[email protected]>
This commit is contained in:
Bulk Renamer
2026-07-03 20:51:20 -05:00
co-authored by Cursor
parent 64d7a30328
commit 87282b0259
5 changed files with 70 additions and 16 deletions
+20
View File
@@ -4,6 +4,7 @@ HSRename - Native Linux GUI for mass renaming files.
Inspired by Bulk Rename Utility (Windows); supports preview and flexible rules.
"""
import sys
import traceback
from pathlib import Path
# Ensure project root is on path when run as script or module
@@ -16,7 +17,26 @@ from PyQt6.QtCore import Qt
from gui.main_window import MainWindow
def _install_exception_logger() -> None:
log_dir = Path.home() / ".config" / "HSRename"
log_dir.mkdir(parents=True, exist_ok=True)
log_file = log_dir / "crash.log"
def _hook(exc_type, exc, tb):
try:
log_file.write_text(
"".join(traceback.format_exception(exc_type, exc, tb)),
encoding="utf-8",
)
except OSError:
pass
sys.__excepthook__(exc_type, exc, tb)
sys.excepthook = _hook
def main():
_install_exception_logger()
QApplication.setHighDpiScaleFactorRoundingPolicy(
Qt.HighDpiScaleFactorRoundingPolicy.PassThrough
)