Skip to content

ci: drop Berkeley DB from the asan job, extend the Qt lsan suppressions - #7576

Open
knst wants to merge 1 commit into
dashpay:developfrom
knst:fix-lsan
Open

ci: drop Berkeley DB from the asan job, extend the Qt lsan suppressions#7576
knst wants to merge 1 commit into
dashpay:developfrom
knst:fix-lsan

Conversation

@knst

@knst knst commented Aug 11, 2026

Copy link
Copy Markdown
Collaborator

Issue being fixed or feature implemented

This PR should replace https://github.com/dashpay/dash/pull/7560/changes
The Linux ASan job exposed two independent dependency-owned lifetime reports:

Qt's process-global DBus connection manager retains 86 bytes across four allocations at shutdown. The same QDBusConnectionManager::executeConnectionRequest report appears on unrelated develop-based PRs.
Berkeley DB 4.8 retains DB_PRIVATE lock objects after reopened environments are torn down and memory-pool file metadata after mock databases are closed.

The previous branch suppressed Berkeley DB's shared __os_malloc allocator and changed Dash wallet environment lifecycle code. The allocator rule was too broad, and the production changes were not the cause of either retained allocation. LeakSanitizer also appends a suppression summary to subprocess stderr, breaking exact stderr checks in wallet_hd.py and tool_wallet.py.

What was done?

For Berkeley DB, do what upstream did in 04a7a7a and stop building it in this job. Upstream's asan job carried -DWITH_BDB=ON and libdb5.3++-dev until that commit, ran the same tool_wallet.py and wallet_hd.py, and never needed a Berkeley DB entry in test/sanitizer_suppressions/lsan; the file has never contained one. BerkeleyEnvironment::Close() here is identical to the last upstream version, so the difference is not wallet code but the dependency: upstream linked the system libdb 5.3 shared library, while this job takes DEP_OPTS="" and so links 4.8.30 statically out of depends. The msan job is already configured the same way.

Qt still needs a suppression, and by symbol rather than by module. Upstream suppresses Qt with leak:libQt6Widgets, which only works for a shared library; with Qt linked statically from depends the allocation belongs to the executable and that form cannot match. Upstream hit this in 5be31b2 and answered it with per-symbol rules, so add QDBusConnectionManager next to the two symbols already taken from that commit.

How Has This Been Tested?

N/A

Breaking Changes

N/A

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation
  • I have assigned this pull request to a milestone

The asan job reports leaks owned by two dependencies: Berkeley DB's lock
table and memory-pool file metadata, and Qt's process-global DBus
connection manager.

For Berkeley DB, do what upstream did in 04a7a7a and stop building it in
this job. Upstream's asan job carried -DWITH_BDB=ON and libdb5.3++-dev until
that commit, ran the same tool_wallet.py and wallet_hd.py, and never needed
a Berkeley DB entry in test/sanitizer_suppressions/lsan; the file has never
contained one. BerkeleyEnvironment::Close() here is identical to the last
upstream version, so the difference is not wallet code but the dependency:
upstream linked the system libdb 5.3 shared library, while this job takes
DEP_OPTS="" and so links 4.8.30 statically out of depends. The msan job is
already configured the same way.

Qt still needs a suppression, and by symbol rather than by module. Upstream
suppresses Qt with leak:libQt6Widgets, which only works for a shared
library; with Qt linked statically from depends the allocation belongs to
the executable and that form cannot match. Upstream hit this in 5be31b2
and answered it with per-symbol rules, so add QDBusConnectionManager next to
the two symbols already taken from that commit.
@knst knst added this to the 24 milestone Aug 11, 2026
@thepastaclaw

thepastaclaw commented Aug 11, 2026

Copy link
Copy Markdown

✅ Final review complete — no blockers (commit 19a28d8)

@thepastaclaw

Copy link
Copy Markdown

Fork CI run for this exact head (19a28d82): https://github.com/thepastaclaw/dash/actions/runs/31507729414

@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown

Review Change Stack

Walkthrough

The native ASan environment no longer installs the Berkeley DB development package. Its Bitcoin configuration disables Berkeley DB and enables SQLite. The LSan suppression list now includes leaks from QDBusConnectionManager.

Estimated code review effort: 1 (Trivial) | ~5 minutes

Possibly related PRs

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly summarizes both main changes: removing Berkeley DB from the ASan job and extending Qt LSan suppressions.
Description check ✅ Passed The description directly explains the dependency leaks, the ASan configuration change, and the added Qt suppression.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands.

@thepastaclaw thepastaclaw left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Final validation — Codex/Sol only (Phase 2 disabled)

At exact head 19a28d8, the ASan job consistently disables Berkeley DB while explicitly retaining SQLite wallet support, and the added QDBusConnectionManager suppression is narrowly scoped to the dependency-owned Qt shutdown allocation. No actionable defects or missing prerequisite claims were identified.
Source: reviewer backend model gpt-5.6-sol; final verifier backend model gpt-5.6-sol. openclaw-agent/cliproxy/gpt-5.6-sol is orchestration-only and is not reviewer evidence.

Validated zero-blocker Codex/Sol precheck evidence was promoted to final because Phase 2 (Sonnet/Opus) is temporarily disabled. This is Codex/Sol-only final validation, not Codex + Sonnet/Opus coverage.

Review provenance

  • Codex reviewers: gpt-5.6-sol — general (completed), gpt-5.6-sol — dash-core-commit-history (completed)
  • Verifier: gpt-5.6-sol — verifier
  • Sonnet/Opus: not run (Phase 2 disabled — temporary Codex/Sol-only final)
  • Secondary pass: disabled (temporary_phase2_sonnet_disable)

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