fix(packaging): verify bundled startup dependencies
This commit is contained in:
@@ -7,11 +7,21 @@ include config files, SQLite databases, Chrome profiles, generated images,
|
||||
logs, prompts, or other operator data.
|
||||
"""
|
||||
|
||||
import importlib.util
|
||||
import os
|
||||
|
||||
from PyInstaller.utils.hooks import collect_data_files
|
||||
|
||||
block_cipher = None
|
||||
try:
|
||||
backports_tarfile_spec = importlib.util.find_spec("backports.tarfile")
|
||||
except ModuleNotFoundError:
|
||||
backports_tarfile_spec = None
|
||||
if backports_tarfile_spec is None:
|
||||
raise SystemExit(
|
||||
"Missing backports.tarfile. Run: "
|
||||
"py -3.10 -m pip install -r requirements-build.txt"
|
||||
)
|
||||
default_prompt_datas = collect_data_files(
|
||||
"app.default_prompts",
|
||||
includes=["**/*.txt"],
|
||||
@@ -36,6 +46,7 @@ a = Analysis(
|
||||
"PySide6.QtCore",
|
||||
"PySide6.QtGui",
|
||||
"PySide6.QtWidgets",
|
||||
"backports.tarfile",
|
||||
],
|
||||
hookspath=[],
|
||||
hooksconfig={},
|
||||
|
||||
Reference in New Issue
Block a user