Repository navigation
[verified] fix(slack): hydrate incomplete mention attachments - #1888
Conversation
|
@guilhermesan is attempting to deploy a commit to the Inbox Zero Team on Vercel. A member of the Team first needs to authorize it. |
[Medium impact] The change reaches Slack’s inbound mention and file workflow. The PR should not merge until failed attachment lookups remain retryable. Findings
SummaryAdds a Slack history lookup for mentions whose file attachments cannot yet be downloaded.
Reviews (3) · Last reviewed commit: "Merge branch 'main' into fix/slack-app-m..." · Reviewed by Greptile |
Playwright screenshotsNo new feature frames; gallery is suite-vs-main drift. Open screenshot gallery · Dashboard · CI run Updated for commit |
| } catch { | ||
| // Missing scopes, deleted files, or unavailable history must not | ||
| // prevent the mention text and original file URLs from arriving. | ||
| getLogger().warn( | ||
| "Slack mention attachment hydration failed; delivering original message", | ||
| ); | ||
| } |
There was a problem hiding this comment.
When Slack history is temporarily unavailable or still lacks the file metadata, this catch delivers the mention without a downloadable attachment. If the sink succeeds, the webhook returns 200 and keeps the deduplication key. Slack cannot retry once the file becomes available, so the bot runs without the file the user asked it to inspect.
Keep temporary hydration failures retryable by recording the failed key and returning 5xx.
# Conflicts: # packages/adapters/src/chat-sdk-surface.ts
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
Summary
Fix Slack file and snippet attachments being dropped when an
app_mentionevent arrives with incomplete file metadata.Slack may deliver the
app_mentionevent before the corresponding message representation contains authenticated, fetchable attachments. In that case, Rakazo receives the mention text but cannot download or expose the attached file to the agent.Changes
app_mentionevents that contain file stubs but no fetchable attachments.fetchMessage(thread.id, message.id).Why
Without this hydration step, Slack snippets can appear in the Slack UI while Rakazo receives only the mention text. The agent then runs without the file and cannot inspect the snippet contents.
Test plan
app_mentioncontent and routing semantics.Configuration note
The Slack app must include the
files:readOAuth scope so private Slack files can be downloaded.