← Back to Pull requests

build: add production Cargo application orchestration #1725

Closed
unknown closed this pull request without merging on Oct 22, 2026 09:18 UTC
View on GitHub
unknown unknown commented on Oct 22, 2026 05:35 UTC
Author

Scope


Refs #1332. Add a production Cargo command for the native Linux hybrid application, sharing its runtime staging with application validation. This PR does not complete #1332. CMake remains authoritative.

  • ./native-build build bootstraps obs-build through Soldr, then runs outside its process tree so the Rust archive build respects Soldr's reentrancy guard.

  • Build only the production hybrid core, frontend API, OpenGL renderer, Qt frontend, selected modules, FFmpeg helper, scripting and optional SDK-backed plugins. C reference binaries and compatibility probes are test-only.

  • Explicit Debug/Release/RelWithDebInfo/MinSizeRel native profiles; configurable core unity/PCH; fresh development runtime and application-build.json per invocation.

  • CMake and Cargo share frontend and Qt wrapper host source inventories. All 35 original CMake source calls retain their exact ordered inputs.

  • Relative Linux library lookup prefers the staged runtime over original build directories. The GUI test no longer injects LD_LIBRARY_PATH.

  • Enabled Tools and original C++ WebSocket plugins are included in the bundled module inventory.

  • Match existing native-consumer Rust compiler-cache bypass policy in both launch paths; standalone native C/C++ caching remains available.
  • RED → GREEN


    The early draft was opened at 2681f83ae: real C profile switching in the existing application test category failed at Release (NDEBUG actual 0, expected 1). Subsequent RED contracts cover shared staging, command parsing, relative runtime core/plugin selection (652fd6f08), bundled frontend feature selection (0c7bc1901), and native Rust cache settings at both subprocess boundaries (27cd7bbdb). Each now passes.

    Real application validation also exposed and fixed missing Qt host/frontend source groups, Soldr reentrancy and native SDK discovery, skipped bundled frontend plugins, and stale C-test build inputs. Existing C test sources/public headers and the WebSocket submodule are unchanged.

    Verified locally


  • Production command built and staged the real Linux application. The exact command-produced runtime passed mapped-window startup, staged core/API/renderer and every selected module, saved scene, Lua/Python load/save/unload callbacks, screenshot, x264/AAC recording with white-frame/media checks, and normal shutdown.

  • Existing compatibility driver passed with both the explicit C reference and hybrid core: dynamic exports, source/module APIs, scripting, frontend Tools dialogs, original WebSocket wire checks, GUI, saved scene, recording and shutdown.

  • 63 selected unchanged C tests per core: 126 successful runs, with selected-core resolution checked for every executable. This is the selected Cargo manifest, not a claim of complete CTest coverage.

  • 21 native build contracts passed; additional bundled-feature and both cache-boundary contracts passed. All tests remain in existing Rust categories.

  • Full local ci/ self-test discovery passes: 934 tests, five environment-dependent skips. The initial PR self-test failure exposed two guards that still expected inline CMake source lists; these now verify the shared inventories, with actual CMake configuration checks for all three Qt wrapper host selectors.

  • Focused Clippy with libobs integration/all targets and warnings denied passes; formatting and whitespace checks pass.
  • Runtime evidence is retained in the bounded obs-cargo-application-build-03ce5a7a87e5 volume. Production runtime: /build/application/relwithdebinfo/runtimes/1792652434341437492-8; compatibility runtimes: /build/compatibility/app-runtime-26aoBw and app-runtime-Hertej. Logs: /tmp/obs-1332-application-build.log, /tmp/obs-1332-application-compatibility.log, and focused RED/GREEN logs. Validation used the existing bounded Docker harness with FFmpeg and an Openbox/Xvfb/D-Bus session; their required packages are in the existing shared dependency list.

    Pre-push review: one reviewer across all buckets and follow-up fixes; final verdict clean.

    The first native Windows Tier 2 run exposed a raw shader-byte assumption in the unchanged test_video_output_plan test: Git's Windows CRLF conversion prevented its LF-delimited technique lookup. e9790f87a reproduces this with an actual Windows-style Git checkout; dc7c6ac30 pins .effect resources to LF. Shader source and C tests remain untouched. The checkout regression plus related guards pass (24 tests); native Windows Tier 2 confirms the original test passes in the CMake reference/hybrid and Cargo reference/hybrid configurations.

    PR CI run 39745867584 passed with CI Gate ✅ on dc7c6ac30: Fast Gate, formatting/self-tests, Qt frontend, Linux C-test modes, Windows/macOS Rust tests and native Tier 2, and Windows/macOS cross lint. The macOS native job completed successfully after 20m24s; the observation timeout did not stop or restart it.

    Remaining acceptance for #1332


    Full macOS/Windows application orchestration, all configurations/architectures and production feature parity (including NVENC selection), complete canonical test/build inventories, controlled cold/warm/no-change/edited-input native-cache and unity/PCH measurements, release metadata/layout, and packaged artifacts run with representative saved capture profiles remain open. Component coverage from earlier PRs and this Linux development runtime are progress, not evidence of all-platform/package completion.

    Diff: 650 lines (+487 / -163) across 8 files Reviewer: alerque Review duration: 222m
    All Vouch review confidence checks passed
    Residual risk 0.22 = Change Risk (0.52) × (1 − Review Confidence (0.57)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.52 · 650 lines diff across 8 files
    0.52
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.17 · 1 substantive comment(s)
    0.17
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    56%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.388
    Shallow Review Depth shallow_review_depth
    0.289
    Real PR Conversation Timeline
    1 comments
    "Review active on #1725"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 56.8% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 52% (MEDIUM) · Higher = larger blast radius
    52%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 56.8% · Lower = rushed or shallow review
    56.8%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 22.5% · Safe to merge
    22.5%