Fix truncation-warning ContextVar leaking between tests

NousResearch/hermes-agent · cluster 93018

Data as of

Nothing open on GitHub. Fix merged in #93395. Check it covers your case.

The short answer

0open issues
0open PRs
6items grouped
Known?
Yes. 6 related items grouped here, 1 issue already closed.
Fix event
A fix was merged to main in PR #93395. Check it covers your case. No release data is tracked.
Tracker
The maintainers' tracker marks this resolved, deciding PR #93395. That is separate from the fix event.
Still open
Nothing open on GitHub.

Multiple issues and PRs address order-dependent test failures caused by a truncation-warning ContextVar leaking across test files, particularly between test_prompt_builder.py and test_system_prompt.py. The work involves isolating or resetting this shared state so tests pass regardless of execution order.

Open issues0

No open issues.

Open PRs0

No open pull requests.

Fixes on record

Merged to main. A stamp counts the issues a fix is linked to.

  • #93395 prompt_builder/system_prompt tests no longer fail when run together (#93018, salvage #93047)

    merged to main

    files: tests/agent/test_prompt_builder.py, tests/agent/test_system_prompt.py

4 PRs closed without merging

From the close comments: duplicate 2 · merged via another change 1 · other 1

  • #93027 test(system-prompt): make build_system_prompt unit test robust to leaked truncation warnings (fixes #93018) · other → 04dd2bb, #93018, #93047, #93395
  • #93038 test(agent): stop truncation-warning ContextVar leaking across test files · duplicate → #93027
  • #93047 test(agent): stop truncation-warning ContextVar leaking between test files · merged via another change → 04dd2bb, #93395
  • #93071 test(agent): isolate truncation warnings between tests · duplicate → #93038, #93018
Closed issues · 1
  • Closed#93018Tests: order-dependent failure — test_prompt_builder.py pollutes test_system_prompt.py truncation-warning ContextVar (reproduces on clean main)
How this cluster was grouped
  • Link evidence (structural links throughout): every member is connected by structural evidence: shared changed files, or a closing/superseded reference.
  • Pairwise link density 0.33: the share of item pairs that carry a link, counting a structural link in full and a relevance-only link at 0.36. 1.00 means every pair is linked.

Pick up a Lab task

Check whether a fix covers the open issues here, with your own agent. Bring back evidence for maintainers.

Open the Lab

At a glance

Merged PRs
#93395
Closed issues
1
Attempts
4 PRs closed without merging
Fix link checked
24 Aug 2026

For your agent

The same facts, typed.