fix(mattermost): preserve thread-local delivery hygiene - #46885
Merged
Conversation
Salvage the valid thread-routing pieces from #41640: - route Mattermost progress/status sends through metadata thread IDs - treat top-level Mattermost channel posts as thread roots for progress - preserve thread metadata through media/file sends - allow flat fallback only for final notify-worthy replies on confirmed broken roots Co-authored-by: Wolfram Ravenwolf <github.com@wolfram.ravenwolf.de>
Contributor
🔎 Lint report:
|
Collaborator
|
Related: #41640 (the WolframRavenwolf PR this salvages thread-routing/delivery-hygiene pieces from), #12063 (the underlying issue: Mattermost adapter ignores metadata.thread_id). Competing/adjacent thread-routing work also in flight: #45654, #45861, #33470. As the salvage that omits the unrelated stream-consumer fallback deletion and display-policy change, this is the focused/authoritative version reviewers can land. |
This was referenced Jun 16, 2026
This was referenced Jul 13, 2026
This was referenced Jul 30, 2026
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.
Summary
Mattermost progress, tool, media, and final-answer deliveries now preserve thread locality without leaking progress noise into flat channels.
Changes
metadata.thread_idin addition toreply_to.source.thread_idin thread mode; DMs do not.Validation
python3 -m py_compile plugins/platforms/mattermost/adapter.py gateway/run.py tests/gateway/test_mattermost.pyuv run --with pytest --with pytest-asyncio --with aiohttp python -m pytest tests/gateway/test_mattermost.py -q -o addopts=Contributor credit
Salvages the valid thread-routing and delivery-hygiene pieces from #41640 by @WolframRavenwolf while omitting the unrelated stream-consumer fallback deletion and Mattermost display-policy change.
Infographic