Skip to content

ci: Install the sanitizer deps from apt-packages.txt - #1487

Merged
zackees merged 3 commits into
obs-rust:masterfrom
rdoupe:ci/sanitizers-deps
Oct 20, 2026
Merged

zackees merged 3 commits into
obs-rust:masterfrom
rdoupe:ci/sanitizers-deps

Conversation

@rdoupe

@rdoupe rdoupe commented Oct 20, 2026

Copy link
Copy Markdown
Collaborator

Refs #1395

What and why

The Sanitizers workflow (asan, tsan, valgrind) has failed every night since 2026-10-16 (last green: run 38731778779, 10-15; first red: 38896638310), in "Install dependencies":

no package list found in .../rust/tools/sanitize/../linux-validate/Dockerfile

Triage then fails with "No results". The runner image is the same on the green and the red runs (ubuntu-26.04 20261012.163.1).

  • rust/tools/sanitize/install-ubuntu-deps.sh read the OBS build packages by scraping the first apt-get install of rust/tools/linux-validate/Dockerfile with awk. ci: Run Tier 2 Linux natively on the runner #967 (10-16) moved that list into rust/tools/linux-validate/apt-packages.txt, which the Tier 2 jobs and the Docker harness now install, so the scrape found nothing.
  • The script now reads apt-packages.txt. Compared with the list it found on 10-15, the shared list drops ccache (sanitize.sh uses the pinned zccache) and adds zstd. The extra launch packages (valgrind, gdb, xvfb, ...) are unchanged.
  • A second failure was hidden behind the first: under the asan pass's -fsanitize=undefined, test_ws_save_changes (obs-websocket: Save the scene collection after changes #812) doesn't link (undefined reference to `typeinfo for WebSocketServer'). The test stubs the server rather than compiling WebSocketServer.cpp, where the class's typeinfo lives, and UBSan's vptr check needs it. sanitize.sh stops the asan pass on any build error. That one target now builds with -fno-sanitize=vptr; ASan and the other UBSan checks still apply to it.

RED → GREEN

  • RED: d7c3d78 ci: Test that the sanitizer deps script installs the Tier 2 package list. ci/test_sanitize_deps.py runs the script against stub sudo/apt-get and checks the packages it installs. It fails on the current script ("no package list found").
  • GREEN: 1e67071 (deps) and a811f44 (vptr). uv run python -m unittest ci/test_sanitize_deps.py passes; all ci/ unittests pass (766, 2 skipped); shellcheck and gersemi are clean. With the vptr change, test_ws_save_changes links and runs under ASan in a local asan build.
  • Not run: the workflow itself. A local docker run ubuntu:26.04 wasn't possible here, and the full local asan build stopped earlier on a -Werror=format-truncation warning from this host's GCC 16.2 at libobs/util/pipe-variadic.c.h:16 (likely a false positive of that GCC, not seen on the runner), so there are no local sanitizer test results. A Sanitizers run on this head is the real check.

Checklist

  • Base is master
  • I claimed the issue, or no one else has an open PR for it
  • Characterization test (if the unit had none), then RED, then GREEN commits
  • User-visible change: its line in docs/features.md is added or updated (not applicable: no user-visible change)
  • (Optional) Local gate passed and the pushed head is stamped; otherwise PR CI runs the full suite

rust/tools/sanitize/install-ubuntu-deps.sh takes the OBS build
dependencies from the package lines of the first apt-get install in
rust/tools/linux-validate/Dockerfile. obs-rust#967 moved those packages to the
shared apt-packages.txt, so the Dockerfile's install line is now one
line that reads that file, and the scrape finds no packages. Every
scheduled asan, tsan and valgrind job since 2026-10-16 stops in
"Install dependencies" with "no package list found in .../Dockerfile",
and Triage then fails for want of results.

The test runs the script against stub sudo and apt-get and checks that
it installs every package in apt-packages.txt plus the launch tools.
It fails on this commit: the script exits 1 before apt-get runs.

Refs obs-rust#1395
Read the OBS build dependencies from
rust/tools/linux-validate/apt-packages.txt, the list the Tier 2 CI jobs
and the Docker harness install since obs-rust#967, instead of scraping the
Dockerfile, whose install line no longer lists any packages. The
Sanitizers workflow has failed in "Install dependencies" on every
nightly run since 2026-10-16 for this reason; the runner image did not
change (ubuntu-26.04 20261012.163.1 on both the last green run and the
failing ones).

Against the list the old scrape found on 2026-10-15, the shared list
drops ccache (sanitize.sh now uses the pinned zccache from
install-zccache.sh) and adds zstd. The extra launch packages are
unchanged.

Refs obs-rust#1395
The sanitizer asan pass builds with -fsanitize=address,undefined, and
UBSan's vptr check makes every member call through WebSocketServer
reference the class's typeinfo. That typeinfo is emitted with its
out-of-line destructor in WebSocketServer.cpp, which the test does not
compile (it stubs GetWebSocketServer() instead), so the link fails:

  undefined reference to `typeinfo for WebSocketServer'

and sanitize.sh stops the asan pass on any build error. The test was
added after the last sanitizer run that got past "Install dependencies",
so no nightly has shown it yet. Turn the vptr check off for this one
stubbed harness; outside a UBSan build the flag does nothing.

Refs obs-rust#1395
@rdoupe
rdoupe requested a review from zackees as a code owner October 20, 2026 02:30
@zackees
zackees added this pull request to the merge queue Oct 20, 2026
Merged via the queue into obs-rust:master with commit 2cddae9 Oct 20, 2026
25 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants