Skip to content

fix(slack): harden rich table block fallback - #513

Open
hashbender wants to merge 1 commit into
mainfrom
mirror/pr-56618
Open

fix(slack): harden rich table block fallback#513
hashbender wants to merge 1 commit into
mainfrom
mirror/pr-56618

Conversation

@hashbender

Copy link
Copy Markdown
Owner

Summary

Fixes a live Slack API regression from the merged NousResearch#56102 rich_blocks table path.

This keeps the selected Block Kit renderer architecture intact and makes a narrow schema/fallback hardening change:

  • emit only valid object entries in table column_settings, never null
  • omit trailing default-left column_settings entries so Slack applies defaults
  • retry once without blocks when Slack rejects a rich Block Kit payload as invalid/too large
  • add regressions for Slack-valid table payloads and no-block retry behavior

Fixes NousResearch#56615

cc @teknium1, this is the focused follow-up from the live validation comment on NousResearch#56102.

Validation

scripts/run_tests.sh tests/gateway/test_slack.py tests/gateway/test_slack_block_kit.py tests/gateway/test_slack_block_kit_adapter.py -q
# 247 tests passed, 0 failed

ruff check plugins/platforms/slack/adapter.py plugins/platforms/slack/block_kit.py tests/gateway/test_slack_block_kit.py tests/gateway/test_slack_block_kit_adapter.py
# All checks passed

git diff --check
# clean

Notes

This intentionally does not port the broader NousResearch#53893 hardening set. Those can be separate follow-ups. This PR only fixes the current merged table-block regression and prevents rich formatting failures from dropping Slack replies.


Mirror-of: NousResearch#56618
NousResearch#56618

@tenki-reviewer

tenki-reviewer Bot commented Jul 1, 2026

Copy link
Copy Markdown

Review Complete
No issues found!

Risk: 🟢 Low (15/100) — no findings · 214 LOC across 4 files


PR adds retry logic to Slack adapter for block-payload rejections and refines Block Kit column_settings rendering. One low-confidence finding was identified below threshold (dead error code in block-rejection detection targeting wrong Slack API surface).

Files Reviewed (4 files)
plugins/platforms/slack/adapter.py
plugins/platforms/slack/block_kit.py
tests/gateway/test_slack_block_kit.py
tests/gateway/test_slack_block_kit_adapter.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Slack rich_blocks table output fails with invalid_blocks due null column_settings

1 participant