Import CBB refresh verify r4 stability baseline
Preserve tested Verify source, authoritative READY checks, bounded bridge retries, diagnostics and failure-only reporting. Include 336-test suite and packaging assets; exclude live Mentor samples, field logs, backups and distributions.
This commit is contained in:
commit
11a2b2e46e
130 files changed
+19267
No files matched your search
@@ -0,0 +1,26 @@
|
||||
param(
|
||||
[string]$PythonExecutable,
|
||||
[string]$OutputDirectory = 'dist'
|
||||
)
|
||||
$ErrorActionPreference='Stop'
|
||||
$root=Split-Path $PSScriptRoot -Parent
|
||||
$py = if($PythonExecutable){$PythonExecutable}elseif(Test-Path "$root\.venv\Scripts\python.exe"){"$root\.venv\Scripts\python.exe"}else{(Get-Command python).Source}
|
||||
$distRoot = if ([IO.Path]::IsPathRooted($OutputDirectory)) {
|
||||
[IO.Path]::GetFullPath($OutputDirectory)
|
||||
} else {
|
||||
[IO.Path]::GetFullPath((Join-Path $root $OutputDirectory))
|
||||
}
|
||||
Push-Location $root
|
||||
try {
|
||||
& $py -m PyInstaller --noconfirm --clean --distpath $distRoot packaging\CbbRefreshVerify.spec
|
||||
if ($LASTEXITCODE -ne 0) { throw "PyInstaller failed: $LASTEXITCODE" }
|
||||
$exe = Join-Path $distRoot 'CbbRefreshVerify-Background\CbbRefreshVerify.exe'
|
||||
if (-not (Test-Path -LiteralPath $exe)) { throw 'PyInstaller 未生成 exe' }
|
||||
$smokeRoot = Join-Path $root ('build\frozen-smoke-' + [guid]::NewGuid().ToString('N'))
|
||||
$process = Start-Process -FilePath $exe -ArgumentList ('--smoke-test --data-root "' + $smokeRoot + '"') -WindowStyle Hidden -PassThru
|
||||
if (-not $process.WaitForExit(30000)) { Stop-Process -Id $process.Id; throw 'Frozen UI smoke timeout' }
|
||||
if ($process.ExitCode -ne 0) { throw "Frozen UI smoke failed: $($process.ExitCode)" }
|
||||
$log = Get-Content -Raw -LiteralPath (Join-Path $smokeRoot 'logs\application.log')
|
||||
if ($log -notmatch 'gui_smoke_window_created' -or $log -notmatch 'application_clean_shutdown exit_code=0') { throw 'Frozen UI lifecycle incomplete' }
|
||||
Write-Output $exe
|
||||
} finally { Pop-Location }
|
||||
@@ -0,0 +1,28 @@
|
||||
from pathlib import Path
|
||||
project_root = Path(SPECPATH).parent
|
||||
assets_root = project_root / 'src' / 'cbb_refresh_verify' / 'assets'
|
||||
bridge_path = project_root / 'tools' / 'status_bridge' / 'bin' / 'CbbStatusBridge32.exe'
|
||||
verify_probe_path = project_root / 'tools' / 'status_bridge' / 'bin' / 'VerifyProbe32.exe'
|
||||
a = Analysis(
|
||||
[str(project_root / 'src' / 'cbb_refresh_verify' / '__main__.py')],
|
||||
pathex=[str(project_root / 'src'), r'F:\Sync Tool Skyworth\Work Maps\dxdesigner-part-replacement\src'],
|
||||
binaries=(
|
||||
[(str(bridge_path), 'tools/status_bridge/bin')] if bridge_path.is_file() else []
|
||||
) + (
|
||||
[(str(verify_probe_path), 'tools/status_bridge/bin')]
|
||||
if verify_probe_path.is_file() else []
|
||||
),
|
||||
datas=[(str(project_root / 'src' / 'cbb_refresh_verify' / 'save_verified_block.vbs'), 'cbb_refresh_verify'),
|
||||
(str(assets_root / 'cbb_refresh_verify.ico'), 'cbb_refresh_verify/assets'),
|
||||
(str(assets_root / 'cbb_refresh_verify.png'), 'cbb_refresh_verify/assets'),
|
||||
(str(assets_root / 'cbb_refresh_verify.svg'), 'cbb_refresh_verify/assets'),
|
||||
(str(assets_root / 'dialog_rules.v1.json'), 'cbb_refresh_verify/assets')],
|
||||
hiddenimports=['win32com.client','win32com.client.dynamic','pythoncom','pywintypes','win32job','pywinauto','pywinauto.uia_defines','pywinauto.controls.uiawrapper','pywinauto.win32_element_info','cbb_refresh_verify.dialog_agent','cbb_refresh_verify.dialog_probe','cbb_refresh_verify.dialog_rules','cbb_refresh_verify.ui.main_window','dx_productivity.trial_task_center.logging_setup','dx_productivity.trial_task_center.errors','dx_productivity.trial_task_center.retention'],
|
||||
excludes=['PySide6.QtDesigner','PySide6.QtMultimedia','PySide6.QtMultimediaWidgets','PySide6.QtOpenGL','PySide6.QtOpenGLWidgets','PySide6.QtPdf','PySide6.QtPdfWidgets','PySide6.QtQml','PySide6.QtQuick','PySide6.QtQuickWidgets','PySide6.QtWebChannel','PySide6.QtWebEngineCore','PySide6.QtWebEngineWidgets'],
|
||||
)
|
||||
excluded_qt_binaries = {'icudt78.dll','icuuc.dll','qpdf.dll','qt6pdf.dll','qt6qml.dll','qt6qmlmeta.dll','qt6qmlmodels.dll','qt6qmlworkerscript.dll','qt6quick.dll','qt6quickwidgets.dll'}
|
||||
a.binaries = [entry for entry in a.binaries if Path(entry[0]).name.casefold() not in excluded_qt_binaries]
|
||||
pyz = PYZ(a.pure)
|
||||
exe = EXE(pyz, a.scripts, [], exclude_binaries=True, name='CbbRefreshVerify', console=False,
|
||||
icon=str(assets_root / 'cbb_refresh_verify.ico'))
|
||||
coll = COLLECT(exe, a.binaries, a.zipfiles, a.datas, name='CbbRefreshVerify-Background')
|
||||
Reference in new issue
Block a user