Release v0.7.1 - Remote Manifest System, Stability Fixes

This commit is contained in:
Omni
2026-07-02 21:04:19 +01:00
parent 6def3b480a
commit e5d329a2dc
96 changed files with 1950 additions and 1382 deletions
@@ -3,9 +3,31 @@ Non-Focus-Stealing Message Service for Jackify
Provides message boxes that don't steal focus from the current application
"""
import logging
import os
import random
import string
import subprocess
import warnings
from typing import Optional
logger = logging.getLogger(__name__)
def open_url(url: str) -> None:
"""Open a URL in the system browser, safe to call from within an AppImage."""
env = os.environ.copy()
if "APPIMAGE" in env or "APPDIR" in env:
for var in ("LD_LIBRARY_PATH", "PYTHONPATH", "PYTHONHOME", "QT_PLUGIN_PATH", "QML2_IMPORT_PATH"):
env.pop(var, None)
try:
subprocess.Popen(
["xdg-open", url], env=env,
stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL,
start_new_session=True,
)
except Exception as e:
logger.warning("Failed to open URL %s: %s", url, e)
from PySide6.QtWidgets import (
QMessageBox, QWidget, QLineEdit, QLabel, QVBoxLayout, QHBoxLayout,
QCheckBox, QTextEdit, QPushButton, QDialog, QDialogButtonBox, QSizePolicy,
@@ -61,14 +83,16 @@ class SafeMessageBox(NonFocusMessageBox):
self._setup_low_safety(danger_action, safe_action)
# --- Fix: For question dialogs, set proceed/cancel button return values, but do NOT call setStandardButtons ---
if is_question and hasattr(self, 'proceed_btn'):
self.proceed_btn.setText(danger_action)
self.proceed_btn.setProperty('role', QMessageBox.YesRole)
self.proceed_btn.clicked.disconnect()
self.proceed_btn.clicked.connect(lambda: self.done(QMessageBox.Yes))
self.cancel_btn.setText(safe_action)
self.cancel_btn.setProperty('role', QMessageBox.NoRole)
self.cancel_btn.clicked.disconnect()
self.cancel_btn.clicked.connect(lambda: self.done(QMessageBox.No))
with warnings.catch_warnings():
warnings.simplefilter("ignore", RuntimeWarning)
self.proceed_btn.setText(danger_action)
self.proceed_btn.setProperty('role', QMessageBox.YesRole)
self.proceed_btn.clicked.disconnect()
self.proceed_btn.clicked.connect(lambda: self.done(QMessageBox.Yes))
self.cancel_btn.setText(safe_action)
self.cancel_btn.setProperty('role', QMessageBox.NoRole)
self.cancel_btn.clicked.disconnect()
self.cancel_btn.clicked.connect(lambda: self.done(QMessageBox.No))
def _setup_high_safety(self, danger_action: str, safe_action: str):
"""High safety: requires typing confirmation code"""
@@ -6,6 +6,7 @@ worker thread management, and completion callbacks.
"""
import logging
import warnings
from pathlib import Path
from typing import Callable, Optional
@@ -301,6 +302,8 @@ class VNVAutomationController(QObject):
dialog.load_items(manager.items)
dialog.finished.connect(lambda _result: self._cancel_manual_download_flow(on_complete, state))
dialog.show()
dialog.raise_()
dialog.activateWindow()
def _cancel_manual_download_flow(self, on_complete, state: dict) -> None:
if state["done"]:
@@ -342,10 +345,12 @@ class VNVAutomationController(QObject):
self._manual_dialog = None
self._manual_manager = None
if dialog is not None:
try:
dialog.finished.disconnect()
except Exception:
pass
with warnings.catch_warnings():
warnings.simplefilter("ignore", RuntimeWarning)
try:
dialog.finished.disconnect()
except Exception:
pass
try:
dialog.close()
except Exception: