Skip to content

fix(website-policy): key blocklist cache on real default config path (salvage #3923) - #58526

Merged
teknium1 merged 1 commit into
mainfrom
salvage/3923-website-policy-cache-key
Jul 5, 2026
Merged

teknium1 merged 1 commit into
mainfrom
salvage/3923-website-policy-cache-key

Conversation

@teknium1

@teknium1 teknium1 commented Jul 4, 2026

Copy link
Copy Markdown
Collaborator

Summary

The website blocklist cache no longer serves a stale policy after HERMES_HOME / default-config-path changes within one process (profile switches, tests): the cache is now keyed on the real resolved default config path instead of a "__default__" sentinel.

Trimmed salvage of bundled PR #3923 by @aydnOktay — this was the one sub-fix still valid; commit carries the contributor's authorship.

Changes

  • tools/website_policy.py load_website_blocklist(): cache key = str(_get_default_config_path()); a home/config-path change now naturally misses the cache (+3/−2).

Validation

Before (main) After
Load policy under home1, switch HERMES_HOME to home2, load again serves home1's rules (stale, reproduced live) serves home2's rules
tests/tools/test_website_policy.py pass

Not salvaged from #3923 (superseded/wrong direction)

  • Matrix voice caching → main's plugin adapter already caches audio/voice incl. encrypted media (strictly better)
  • Slack auth_test sync/coroutine shim → written to appease test mocks; Fix Slack multi-workspace token and routing regressions #3928 covers the real connect() issues
  • Codex empty-model default → main deliberately fails loud in _preflight_codex_api_kwargs
  • supply-chain gh pr comment || true → main already uses || echo ::warning

Infographic

pr-3923-salvage

The cache used a '__default__' sentinel as its path key, so switching
HERMES_HOME (profiles, tests) within one process kept serving the stale
policy loaded from the previous home. Key the cache on the actual
resolved default config path instead, so a home/config-path change
naturally misses the cache.

Trimmed from bundled PR #3923 (the other sub-fixes are superseded on
main); authored by @aydnOktay.
@alt-glitch alt-glitch added type/bug Something isn't working tool/web Web search and extraction area/config Config system, migrations, profiles P3 Low — cosmetic, nice to have labels Jul 4, 2026
@teknium1
teknium1 merged commit b3c7b34 into main Jul 5, 2026
31 checks passed
@teknium1
teknium1 deleted the salvage/3923-website-policy-cache-key branch July 5, 2026 07:45
habarmc1223-sudo pushed a commit to habarmc1223-sudo/hermes-agent-fluxmem that referenced this pull request Jul 8, 2026
…website-policy-cache-key

fix(website-policy): key blocklist cache on real default config path (salvage NousResearch#3923)
santhreal pushed a commit to santhreal/hermes-agent that referenced this pull request Jul 13, 2026
…website-policy-cache-key

fix(website-policy): key blocklist cache on real default config path (salvage NousResearch#3923)
Gravezzz pushed a commit to Gravezzz/hermes-agent that referenced this pull request Jul 21, 2026
…website-policy-cache-key

fix(website-policy): key blocklist cache on real default config path (salvage NousResearch#3923)
leewenjie pushed a commit to leewenjie/hermes-agent that referenced this pull request Aug 7, 2026
…website-policy-cache-key

fix(website-policy): key blocklist cache on real default config path (salvage NousResearch#3923)
melon-xf added a commit to melon-xf/hermes-agent that referenced this pull request Sep 3, 2026
…website-policy-cache-key

fix(website-policy): key blocklist cache on real default config path (salvage NousResearch#3923)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/config Config system, migrations, profiles P3 Low — cosmetic, nice to have tool/web Web search and extraction type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants