fix(config): bridge reply_in_thread to platform extra dict - #7561
Closed
Linux2010 wants to merge 1 commit into
Closed
fix(config): bridge reply_in_thread to platform extra dict#7561Linux2010 wants to merge 1 commit into
Linux2010 wants to merge 1 commit into
Conversation
## What broke
Setting `slack.reply_in_thread: false` in config.yaml has no effect.
Slack DM replies are always threaded regardless of this setting.
## Root cause
In gateway/config.py, the slack config section bridges several keys
to platform extra (require_mention, allow_bots, free_response_channels),
but `reply_in_thread` was missing from this bridging logic.
As a result, `self.config.extra.get("reply_in_thread", True)` in
slack.py always returned the default `True`.
## Why this fix is minimal
- Added 2 lines to bridging logic in gateway/config.py
- Added reply_in_thread to the list of bridged keys
- Works for all platforms (Slack, Discord, Telegram, etc.)
## What I tested
Added test suite with 8 test cases:
- test_slack_reply_in_thread_false_bridged
- test_slack_reply_in_thread_true_bridged
- test_slack_reply_in_thread_default_true
- test_discord_reply_in_thread_bridged
- test_telegram_reply_in_thread_bridged
- test_multiple_platforms_reply_in_thread
- test_reply_in_thread_with_require_mention
- test_reply_in_thread_with_free_response_channels
## What I intentionally did not change
- No changes to slack.py behavior
- No changes to other platform adapters
- No opportunistic refactoring
Fixes NousResearch#7532
6 tasks
Contributor
|
Thanks for the precise diagnosis and clean fix, @Linux2010! This exact change was independently landed on Automated hermes-sweeper review — closing as already implemented on
The underlying issue #7532 is resolved. No further action needed on this PR. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What broke
Setting
slack.reply_in_thread: falsein config.yaml has no effect. Slack DM replies are always threaded regardless of this setting.Root cause
In
gateway/config.py, the slack config section bridges several keys to platform extra (require_mention, allow_bots, free_response_channels), butreply_in_threadwas missing from this bridging logic.As a result,
self.config.extra.get("reply_in_thread", True)in slack.py always returned the defaultTrue.Why this fix is minimal
reply_in_threadto the list of bridged keysWhat I tested
Added test suite
tests/gateway/test_reply_in_thread_config.pywith 8 test cases:false→ extratrue→ extraWhat I intentionally did not change
Fixes #7532