Skip to content

rust: Port the VST3 scanner and discovery cache - #5542

Merged
zackees merged 4 commits into
masterfrom
port/vst3-scanner
Nov 24, 2026
Merged

zackees merged 4 commits into
masterfrom
port/vst3-scanner

Conversation

@zackees

@zackees zackees commented Nov 23, 2026 •

Copy link
Copy Markdown
Member

Based on master after #5540 merged.

Fixes #5535. Refs #5534.

Implementation

  • Port scanner path discovery, JSON5 module metadata, SDK factory enumeration, atomic cache publication and the completion protocol to Rust.
  • Use vst3 0.3.0 bindings generated from the same MIT-licensed SDK header revision as the C++ host. Keep module handles live through factory release, then call the platform unload hook. Verified binding provenance and ABI probe
  • Keep CMake's native entry point for argv, process setup and package signing. The Cargo application build uses the Rust executable. The original C++ scanner remains available as a reference for the parity test.
  • Preserve the v1 cache and .bak recovery. Rust uses a separate temporary file for each publication, so overlapping scans cannot write to the same temporary file. Rust also skips failed factory class queries and unreadable search directories while continuing to scan other entries.

RED → GREEN

  • RED 7aafa095a added three cases to the existing obs-tests-app harness. They failed at the intended stub.
  • GREEN cd9f5a605 implements the helper. All four focused tests passed, including valid backup recovery and current-candidate filtering.
  • Both the CMake built helper and the Cargo CLI matched the original C++ helper's cache and status. Linux native CMake ran parity before the unchanged host integration test, and ran the unchanged host against both installs, each containing only its intended helper. The Linux package variant uses obs-studio-rust-vst3-scanner and the unbranded build uses obs-vst3-scanner. The SDK-free disabled graph exposed no VST3 targets.
  • Mutation check changed instrument classification in a scratch build and confirmed the scanner parity check rejected it.
  • Client Clippy and Dylint passed on all six target triples. These checks compile the platform loader branches. Installed runtime execution was verified on Linux.
  • Test cost on Linux across 20 repeats: 4.60 s total for parity plus host integration. Longest individual run 0.17 s and peak RSS 28,464 KiB.

Cached build repair

The original cached Cargo release build omitted the scanner's Rust library and could not link the scanner executable. The single-output scanner library and native archive build successfully with caching enabled. The restored CMake build passes the Rust/C++ scanner comparison and the existing host CTest. The locked Cargo release executable also builds.

Client lint and validators passed. The Linux suite passed 9,741 workspace tests and all 920 utility tests, plus doctests. The optional Windows GNU cross-link was interrupted for checkout handoff, so ordinary hosted CI remains required.

The rebased head passed client lint, Clippy and Dylint across all six target triples. Hosted PR CI remains required because the local client-checks lane could not find xmllint.

Windows fixture correction

The Windows Rust test exposed mixed separators in the fixture expectation. Commit b2d687fa uses native path joins to match the scanner cache path on each platform. The five focused scanner tests passed locally. Hosted PR validation and verify-only package validation are running on the exact pushed head.

@zackees zackees changed the title test(obs-vst3): characterize scanner status and cache (Refs #5535) rust: Port the VST3 scanner and discovery cache Nov 23, 2026
@zackees
zackees changed the base branch from master to feat/5532-vst3-host November 23, 2026 22:21
@obs-rust-project-manager obs-rust-project-manager Bot moved this to In progress in obs-rust Multiview Nov 24, 2026
Base automatically changed from feat/5532-vst3-host to master November 24, 2026 21:39
Ci-Attestation: {"at":1795474440,"gate":"general/all/client-lint","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"13ba03a4a8614865ad1294729660d3dc","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474441,"gate":"rust/aarch64-apple-darwin/client-clippy","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"0f0ec0653daaddb5789488632c29fbd0","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474441,"gate":"rust/aarch64-apple-darwin/client-dylint","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"4c590537d70d4f85614cde12c7f2c677","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/aarch64-pc-windows-msvc/client-clippy","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"24af5476692940bcde6823e8b7214283","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/aarch64-pc-windows-msvc/client-dylint","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"d77d0dc81d019c647e017cde7a8e03df","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/aarch64-unknown-linux-gnu/client-clippy","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"98b747e6eebfe650ca45985f149e5b25","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/aarch64-unknown-linux-gnu/client-dylint","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"5b770a4718018ec692cb6d0919471d98","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/x86_64-apple-darwin/client-clippy","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"9044e2f40ba049e426f692351a5efc9b","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474441,"gate":"rust/x86_64-apple-darwin/client-dylint","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"b6851eec4157b221162e1e52680b6e7b","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/x86_64-pc-windows-msvc/client-clippy","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"9691deff3bfbb89cf93a5947f703252e","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/x86_64-pc-windows-msvc/client-dylint","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"81133f41772f032fe448c0b34d3f1939","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/x86_64-unknown-linux-gnu/client-clippy","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"7cdd33157b8e1bb9f1f00d5e7b723671","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
Ci-Attestation: {"at":1795474440,"gate":"rust/x86_64-unknown-linux-gnu/client-dylint","host":"linux-x86_64","key":"b548bedc82009eb4c2c96f6a0773815e0dc3cb52e0b387ee335546388083b1e2","lane":"client-lint","parents":["bd554a82ae43d93aa35366e4518bea477e0da51a"],"secs":80,"stamp":"1b172565b13a2701d08c8e1d98c598ce","tree":"4229ee96669b9fffc2e7eda051e246430f453e10","v":1,"via":"run"}
… (Refs #5535)

Ci-Attestation: {"at":1795484517,"gate":"data/all/compatibility","host":"linux-x86_64","key":"","lane":"client-checks","parents":["d3b500ef193bdea2c32d44c9d1a52045d16f9d0d"],"secs":226,"stamp":"18d7b8835525794147ebe96bf4da1600","tree":"714282d48278adcf78b8e5e9af80e484f647a273","v":1,"via":"run"}
Ci-Attestation: {"at":1795484517,"gate":"data/all/flatpak-manifest","host":"linux-x86_64","key":"","lane":"client-checks","parents":["d3b500ef193bdea2c32d44c9d1a52045d16f9d0d"],"secs":226,"stamp":"db88f0fde7b1673205785e2a4e151211","tree":"714282d48278adcf78b8e5e9af80e484f647a273","v":1,"via":"run"}
Ci-Attestation: {"at":1795484517,"gate":"data/all/qt-xml","host":"linux-x86_64","key":"","lane":"client-checks","parents":["d3b500ef193bdea2c32d44c9d1a52045d16f9d0d"],"secs":226,"stamp":"452131e418d852cb386178e87d3bbe85","tree":"714282d48278adcf78b8e5e9af80e484f647a273","v":1,"via":"run"}
Ci-Attestation: {"at":1795484517,"gate":"data/all/services-schema","host":"linux-x86_64","key":"","lane":"client-checks","parents":["d3b500ef193bdea2c32d44c9d1a52045d16f9d0d"],"secs":226,"stamp":"bcc7ed5d8b83615d926527b03738dc7c","tree":"714282d48278adcf78b8e5e9af80e484f647a273","v":1,"via":"run"}
Ci-Attestation: {"at":1795556801,"gate":"general/all/client-lint","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"ea9db5fe8b076dddee0b241786d30a45","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795484517,"gate":"python/all/self-test","host":"linux-x86_64","key":"","lane":"client-checks","parents":["d3b500ef193bdea2c32d44c9d1a52045d16f9d0d"],"secs":226,"stamp":"99a707073e7f4b4c3f5da49530987cfb","tree":"714282d48278adcf78b8e5e9af80e484f647a273","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/aarch64-apple-darwin/client-clippy","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"9ec1ad2eed336174b4d65ec2093124a0","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/aarch64-apple-darwin/client-dylint","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"7adc1c6d8ea037f1293a848152fb5b9f","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/aarch64-pc-windows-msvc/client-clippy","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"78f617dfa5e3a55e5f9cfa678530bbad","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/aarch64-pc-windows-msvc/client-dylint","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"b024ff8784eeecf6bb14c62f3d33a579","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/aarch64-unknown-linux-gnu/client-clippy","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"888ea2e837a211e5352fa671b4a841e8","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/aarch64-unknown-linux-gnu/client-dylint","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"117c176e34b0ddc1c9cbdd5708505fbf","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/x86_64-apple-darwin/client-clippy","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"082a377789a969f5c021365c9c33a835","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/x86_64-apple-darwin/client-dylint","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"d4ab8314045be49d07e42fdb8d2cedde","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/x86_64-pc-windows-msvc/client-clippy","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"cb23432d14710a71f644721b904f8db7","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556802,"gate":"rust/x86_64-pc-windows-msvc/client-dylint","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"1b297251a3a767fb77ec9cc24c953d7d","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556801,"gate":"rust/x86_64-unknown-linux-gnu/client-clippy","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"c382d5a3db7a770bdc4fd6c4e0d0a3d6","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
Ci-Attestation: {"at":1795556801,"gate":"rust/x86_64-unknown-linux-gnu/client-dylint","host":"linux-x86_64","key":"ecdd313dfcdcdd2f5b4ed8f415b332dce561bee952534243e46c397aff643a14","lane":"client-lint","parents":["cd9f5a605d7b136e7331d6fb58ba055293a825c5"],"secs":270,"stamp":"55350ec66dd79756e61b07781e6b5761","tree":"8d643a67c5ec21f32cfe7cf20a49455fd665a826","v":1,"via":"run"}
@zackees

zackees commented Nov 24, 2026

Copy link
Copy Markdown
Member Author

Exact pushed head b2d687faaf5257e8219bcf4e42fb3974a69c1c5f passed the installed Linux x86-64/X11 probe with the same two-class fixture used for upstream OBS. The packaged host launched the Rust scanner, discovered both classes, processed gain, restored state, bypassed a missing effect, and reopened the native editor. The Linux artifact's SHA-256 matched the published digest.

The packaged probes also passed on Intel macOS and Apple silicon. The Windows x64 run has built OBS, the probe, and the MSI, with runtime verification pending.

@zackees
zackees marked this pull request as ready for review November 24, 2026 22:38
@zackees

zackees commented Nov 24, 2026

Copy link
Copy Markdown
Member Author

Exact published head b2d687fa also passed the Windows x64 installed-package Collect and verify probe, including the signed package. Together with the Linux and both macOS package probes, this completes native scanner acceptance for #5535. Windows job https://github.com/obs-rust/obs-studio/actions/runs/45497286186/job/138813809421

@zackees
zackees added this pull request to the merge queue Nov 24, 2026
Merged via the queue into master with commit 66e7d91 Nov 24, 2026
102 checks passed
@zackees
zackees deleted the port/vst3-scanner branch November 24, 2026 23:01
@obs-rust-project-manager obs-rust-project-manager Bot moved this from In progress to Done in obs-rust Multiview Nov 25, 2026

This branch was previously deployed

1 inactive deployment
bouf — b2d687fa Deployed Nov 24, 2026 by zackees via Build windows x64 🧱 #193
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

rust: Port the VST3 scanner and discovery cache to obs-vst3

1 participant