Skip to content

fix(ci): stop the nightly 100K Rust recall gate from timing out - #1302

Closed
cyberlife-coder wants to merge 1 commit into
developfrom
claude/admiring-fermi-vp1ou7
Closed

cyberlife-coder wants to merge 1 commit into
developfrom
claude/admiring-fermi-vp1ou7

Conversation

@cyberlife-coder

@cyberlife-coder cyberlife-coder commented Jul 2, 2026 •

Copy link
Copy Markdown
Owner

⚠️ Target branch note

This session's branch is platform-assigned as claude/admiring-fermi-vp1ou7, which doesn't match this repo's Git-Flow prefix allow-list (fix/*, ci/*, etc.) enforced by pr-governance.yml, and the commit's author identity (noreply@anthropic.com, fixed by the execution environment) will trip the "Reject AI-attributed commits" check. Both gates will likely fail automatically — flagging this now so you can cherry-pick the two-file diff onto a compliant branch/identity if you want it merged as-is, same as with #1289.

Description

No open PRs or open issues existed in the repo at the start of this run, so I audited CI health on develop and found: every run of the nightly "Scheduled Rust 100K recall (Fast/Balanced/Accurate/Perfect)" job has been cancelled at its 60-minute timeout since it was added on 2026-06-24 — 8 consecutive nightly failures (runs #307–#351), confirmed via the Actions API. This gate exists to validate HNSW recall@10 across all four quality modes at 100K scale; it has never once produced a pass/fail signal.

Fixes # (no tracking issue existed for this — found via CI audit)

Root cause (two compounding issues)

  1. 4x redundant fixture build. scale_recall_100k.rs built a fresh 100K-vector HNSW index from scratch in each of 4 separate #[test] fns (one per quality mode), despite the fixture helper's own doc comment claiming it was "shared across tests" — it was only a shared function, never shared state. Index construction dominates the gate's runtime, so this alone was a 4x cost multiplier.
  2. Debug-mode perf test. The CI step ran cargo test without --release. Debug-mode HNSW insert/search at 100K vectors is an order of magnitude slower, and it's the only perf-sensitive job in this workflow that made that mistake — its sibling Python 100K job's own comment already states "Release build is mandatory for a perf gate."

Changes

  • crates/velesdb-core/tests/scale_recall_100k.rs: merged the four #[test] fns into one (scale_100k_recall_all_qualities) that builds the fixture once and asserts all four per-mode thresholds, collecting failures instead of stopping at the first.
  • .github/workflows/perf-gate-e2e.yml: added --release to the cargo test invocation for this job.

Type of Change

  • 🐛 Bug fix (non-breaking change which fixes an issue)
  • 🔧 Refactoring (no functional changes to what's being validated)
  • ⚡ Performance improvement

How Has This Been Tested?

  • Ran the refactored test locally in release mode: 112s total (previously never completed within the 60-minute CI budget). All four thresholds still pass at the same values: Fast 0.9440 (≥0.90), Balanced 0.9740 (≥0.95), Accurate 0.9970 (≥0.98), Perfect 1.0000 (=1.00).
  • cargo fmt --check -p velesdb-core — clean
  • cargo clippy -p velesdb-core --test scale_recall_100k --release --features persistence -- -D warnings -D clippy::pedantic — clean
  • cargo check -p velesdb-core --tests --features persistence (dev profile) — compiles
  • Workflow YAML re-validated with yaml.safe_load

Test Configuration:

  • OS: Linux (Ubuntu, containerized)
  • Rust version: stable (workspace default)

Checklist

  • My code follows the style guidelines of this project
  • I have performed a self-review of my code
  • My changes generate no new warnings
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published — n/a, no dependent changes

Additional Notes

No functional/behavioral change to what's validated — same four thresholds, same brute-force ground truth, same single-threaded execution constraint (shared filesystem state per CLAUDE.md). Purely a runtime-efficiency and CI-config fix so the gate can actually run to completion.

Every run of "Scheduled Rust 100K recall (Fast/Balanced/Accurate/Perfect)"
since it was added on 2026-06-24 has been cancelled at its 60-minute
timeout — 8 consecutive nightly failures, confirmed via the Actions API.

Two compounding causes:
- `scale_recall_100k.rs` built a fresh 100K-vector HNSW index from
  scratch in each of 4 separate #[test] fns (one per quality mode)
  instead of sharing one fixture across all four recall checks, despite
  the fixture's own doc comment claiming it was "shared across tests".
- The CI step ran `cargo test` without `--release`; debug-mode HNSW
  insert/search at 100K vectors is an order of magnitude slower, and no
  other perf-sensitive job in this workflow makes that mistake.

Fix: merge the four tests into one that builds the fixture once and
asserts all four thresholds, and add --release to the CI invocation.
Verified locally in release mode: 112s total (previously never
completed in 60 min), all four thresholds still pass at the same
values (Fast 0.944, Balanced 0.974, Accurate 0.997, Perfect 1.000).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01JRKmKy3vWHN55DSaPFkotE
@github-actions

github-actions Bot commented Jul 2, 2026

Copy link
Copy Markdown
Contributor

Thank you for your contribution to VelesDB!

Before this PR can be merged, please sign the Contributor License Agreement by posting the following comment:

I have read the CLA Document and I hereby sign the CLA

This grants the project a license to use your contribution under the VelesDB Core License 1.0 and future licensing terms.


I have read the CLA Document and I hereby sign the CLA


You can retrigger this bot by commenting recheck in this Pull Request. Posted by the CLA Assistant Lite bot.

@codacy-production

Copy link
Copy Markdown

Up to standards ✅

🟢 Issues 0 issues

Results:
0 new issues

View in Codacy

NEW Get contextual insights on your PRs based on Codacy's metrics, along with PR and Jira context, without leaving GitHub. Enable AI reviewer
TIP This summary will be updated as you push new changes.

@cyberlife-coder

Copy link
Copy Markdown
Owner Author

Superseded by #1305 (merged) — same fix, cherry-picked onto a Git-Flow-compliant branch/identity since this PR's own body flagged it would fail the branch-prefix and AI-attribution governance gates. Closing in favor of #1305.

@cyberlife-coder
cyberlife-coder deleted the claude/admiring-fermi-vp1ou7 branch July 10, 2026 15:22
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