Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion apps/windows-studio/src/packlab_studio/build_smoke.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,11 @@
FRAME_ID = "packlab-frozen-capability-frame:v1"
OCP_VERSION = "7.9.3.1.1"
OPEN3D_VERSION = "0.20.0"
# Blender is an optional owner-installed executable. COLMAP and OpenMVS are staged
# unmodified under engines/ beside PackLabStudio.exe and run as separate processes
# (PL-0444, tools/packaging/engine_bundle_manifest.json).
EXTERNAL_DEPENDENCIES_NOT_BUNDLED = ("Blender",)
BUNDLED_EXTERNAL_PROCESS_ENGINES = ("COLMAP", "OpenMVS")


def _required(condition: bool, code: str) -> None:
Expand Down Expand Up @@ -395,7 +400,8 @@ def run_frozen_capability_smoke() -> dict[str, object]:
"status": "PASS",
"network": "NONE",
"capability_groups": groups,
"external_architecture_dependencies_not_bundled": ["Blender", "COLMAP", "OpenMVS"],
"external_architecture_dependencies_not_bundled": list(EXTERNAL_DEPENDENCIES_NOT_BUNDLED),
"bundled_external_process_engines": list(BUNDLED_EXTERNAL_PROCESS_ENGINES),
}
output_path = os.environ.get("PACKLAB_RUNTIME_CAPABILITIES_PATH")
if not output_path:
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# CLAUDE_PEER_REVIEW - Build smoke manifest: PL-0444 engines listed as bundled (PR #113)

- Reviewer: Claude Code independent peer reviewer (did not author the change)
- Source: Sekiph82/PackLab PR #113, branch fix/build-smoke-bundled-engines, head b8f412a7, base e9b5d4a1
- Verdict: CLAUDE_PEER_AUDITED_PASS (no blocking findings; 2 LOW advisories)

## Change
apps/windows-studio/src/packlab_studio/build_smoke.py: EXTERNAL_DEPENDENCIES_NOT_BUNDLED=("Blender",),
BUNDLED_EXTERNAL_PROCESS_ENGINES=("COLMAP","OpenMVS"); manifest adds key bundled_external_process_engines.
tests/studio/test_build_smoke.py: new test ties names to tools/packaging/engine_bundle_manifest.json engine ids.

## Verification
- Claim true: windows-studio-build.yml:1096-1106 stages engines into build\windows-studio\PackLabStudio\engines
and executes colmap.exe; PackLabStudio.iss:27 recursively packages StageDir, so engines\ is installer input.
- Redistribution remains blocked: "Enforce redistribution clearance" (:1192-1206) gates installer; engine
registry entries unresolved pending legal review (:1098-1100). The manifest key does not assert licence clearance.
- Consumers: no workflow/tool/test reads external_architecture_dependencies_not_bundled; installed smoke
(:1328-1347) and pl0351 clean installer smoke (:154-196) read only status/network/revision/version/groups;
no strict schema, so the new key is compatible. Historical PL-0349/0350/0351 records are superseded evidence.
- Mutation: revert to old literal, old constant, drop OpenMVS, drop new key, full base revert -> new test fails (5/5).

## Evidence (reviewer-run, local worktree at b8f412a7)
- pytest tests/studio/test_build_smoke.py tests/ci/test_windows_studio_build_workflow.py: 22 passed
- ruff check core apps server tools tests: All checks passed
- mypy --no-incremental core apps server tools: no issues in 352 source files
- GitHub Actions run for b8f412a7: NOT_VERIFIED by this reviewer (coordinator checks PR CI before merge)

## Advisories (follow-up, non-blocking)
- A1 LOW tests/studio/test_build_smoke.py:313-315 - source-text inspect assertions are brittle; replace with a
behavioural test that runs run_frozen_capability_smoke() with patched probes and asserts the written JSON.
- A2 LOW build_smoke.py:53-54,403-404 - bundled list is a static declaration; the pre-staging packaged smoke
(workflow :1023) writes it before engines exist (:1096). Optionally verify engines/ presence in frozen mode or
label the field as declared packaging intent plus redistribution NOT_CLEARED.
17 changes: 17 additions & 0 deletions tests/studio/test_build_smoke.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
from __future__ import annotations

import inspect
import json
from pathlib import Path
from types import SimpleNamespace

from tools.packaging import packlab_studio_entry
Expand Down Expand Up @@ -296,3 +299,17 @@ def fail_to_create_window() -> None:
"diagnostic omitted because it contains an absolute path\n"
)
assert str(tmp_path) not in log_path.read_text(encoding="utf-8")


def test_smoke_manifest_lists_pl0444_engines_as_bundled_and_only_blender_as_external() -> None:
manifest = json.loads(
(
Path(__file__).resolve().parents[2] / "tools/packaging/engine_bundle_manifest.json"
).read_text(encoding="utf-8")
)
staged = {engine["id"] for engine in manifest["engines"]}
assert {name.casefold() for name in build_smoke.BUNDLED_EXTERNAL_PROCESS_ENGINES} == staged
assert build_smoke.EXTERNAL_DEPENDENCIES_NOT_BUNDLED == ("Blender",)
source = inspect.getsource(build_smoke.run_frozen_capability_smoke)
assert '"bundled_external_process_engines": list(BUNDLED_EXTERNAL_PROCESS_ENGINES)' in source
assert "list(EXTERNAL_DEPENDENCIES_NOT_BUNDLED)" in source