test/docs(slack): force-clear new gating env vars; document new options

- Add SLACK_THREAD_REQUIRE_MENTION, SLACK_IGNORE_OTHER_USER_MENTIONS and
  SLACK_REQUIRE_MENTION_CHANNELS to the conftest behavioral-env force-clear
  list so config-loader side effects can't leak between tests (same class
  of leak the existing SLACK_* entries guard against).
- Document thread_require_mention and require_mention_channels in the
  Slack messaging guide next to the other mention-gating options.
This commit is contained in:
Teknium 2026-07-22 08:33:06 -07:00
parent 2c159f00e4
commit f31c10a0da
2 changed files with 18 additions and 0 deletions

View file

@ -317,6 +317,9 @@ _HERMES_BEHAVIORAL_VARS = frozenset({
# Force-clear on every test setup so the leak can't happen.
"SLACK_REQUIRE_MENTION",
"SLACK_STRICT_MENTION",
"SLACK_THREAD_REQUIRE_MENTION",
"SLACK_IGNORE_OTHER_USER_MENTIONS",
"SLACK_REQUIRE_MENTION_CHANNELS",
"SLACK_FREE_RESPONSE_CHANNELS",
"SLACK_ALLOW_BOTS",
"SLACK_REACTIONS",

View file

@ -501,6 +501,21 @@ slack:
# auto-engagement. Opt-in; default off. Env: SLACK_IGNORE_OTHER_USER_MENTIONS.
ignore_other_user_mentions: false
# Require an explicit @mention for THREAD replies, while leaving
# top-level channel messages governed by require_mention /
# free_response_channels. Narrower than strict_mention: use it when a
# free-response bot should not join every follow-up in busy threads.
# Opt-in; default off. Env: SLACK_THREAD_REQUIRE_MENTION.
thread_require_mention: false
# Per-channel force-mention override — the opposite direction of
# free_response_channels. Channels listed here ALWAYS require an
# explicit @mention, even when require_mention is false globally.
# Ongoing conversations still auto-follow (mentioned threads, active
# sessions, bot-authored threads). Comma-separated IDs or a list.
# Env: SLACK_REQUIRE_MENTION_CHANNELS.
require_mention_channels: ""
# Custom mention patterns that trigger the bot
# (in addition to the default @mention detection)
mention_patterns: