Repository navigation
docs: fix stale example, dispatch, and retry text - #132
Conversation
…rding The state READMEs now point at the tutorial sections that hold the tunnel and the channels:history setup, and show the reply as the Markdown that main.go posts. The Linear README says UpdateSession replaces the external links.
DispatchDeferred starts the handler before it returns to the adapter, so the acknowledgement and the handler run at the same time. The retry deadline check and MaxElapsed bound only the backoff sleep, not the HTTP attempts. newFirstThoughtDeadline falls back to now() for a bad timestamp.
Chat.prelude routes commands and interactions. Chat.queuePollInterval holds the ThreadLockTTL/20 value and its clamp.
Queue, debounce, and burst make the handler wait, so the ack and the handler do not always run at the same time. Name the caller's context the same way in the Slack retry paragraph, and drop the SleepCtx sentence that described its callers.
|
@codex review |
|
@codex security review |
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
🛡️ Codex Security ReviewSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
The retry deadline check and MaxElapsed bound only the backoff sleep, and DispatchDeferred acknowledges without waiting for the handler. Correct the copies of the old claims in CONTEXT.md, docs/, the Slack retry comments, the ratelimit README, and the Linear example.
|
@codex review |
|
@codex security review |
|
Codex Review: Didn't find any major issues. 🚀 Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
🛡️ Codex Security ReviewSecurity review completed. No security issues were found in this pull request. Reviewed commit: Only the user who started this review can view the report in Codex. ℹ️ About Codex security reviews in GitHubThis is an experimental Codex feature. Security reviews are triggered when:
Once complete, Codex will leave suggestions, or a comment if no findings are found. |
…retry docs (#137) ## Why The operator wants every open follow-up issue in coder/chat closed by one small, reviewed PR. This PR closes the five Slack adapter and retry-doc follow-ups from the reviews of #132 and #133, as the triage comment on #136 decided them. ## What changed - `chat.postEphemeral` no longer gets a `mrkdwn` field. Slack lists no such argument for that method, so `slackapi.PostEphemeralRequest` loses `Mrkdwn`. The DM fallback keeps `"mrkdwn": false` on `chat.postMessage`, and a test now pins it. - The `withDefaults` comment states the real worst-case backoff: 2s (`MaxElapsed`) with a Slack `Retry-After`, not about 600ms. ADR 0005 decision 3 now states only the bounds, with a dated amendment note that points to #132. Decision 4 and two Consequences drop the same ack-window claim. - A comment at the `PostNative` payload says why it skips the typed `PostMessage`: `[]slackapi.Block` models only three block types, and the docs call the payload opaque Block Kit. Closes #136 ## Scope - No caller or test relied on `mrkdwn: false` for literal ephemeral text, so the text gets no escape. - Plain Text in a native ephemeral message keeps Slack's mrkdwn parsing. Slack has no `mrkdwn` argument on `chat.postEphemeral`, so the dropped field likely never turned parsing off. I did not verify this against a live workspace. CONTEXT.md and the interactive-components how-to now record this exception. - `adapters/linear/retry.go` had the same stale 600ms comment, and this PR corrects it too. ## Blast Radius `slackapi.PostEphemeralRequest.Mrkdwn` is an exported field, so a caller that sets it stops compiling. The field had no documented effect on Slack. ## Verification - The two new ephemeral tests fail on the test commit and pass on the fix commit. The DM-fallback test fails when the fallback stops sending `mrkdwn`. - A local 429 server that always sends `Retry-After: 1` made the default policy return `RateLimited` after 2.01s and three attempts. - `go vet`, `go test` for every module, `gofmt -l`, and `go test -race ./adapters/slack/...` pass. --- _Generated with [`xum`](https://github.com/coder/xum) • Model: `anthropic:claude-opus-5-5` • Thinking: `high`_
Why
The operator wants every open follow-up issue in coder/chat closed by one small, reviewed PR. This one fixes sentences in docs and doc comments that no longer match the code on main.
What changed
channels:historyscope, and show the reply as the Markdown thatmain.goposts. The Linear example README says the app replaces the external links. It no longer says the app adds one.DispatchDeferredacknowledges without waiting for the handler, so the handler can act before the acknowledgement is written. The root README,doc.go,CONTEXT.md(Dispatch Mode, Ack-Then-Work, Detached Work Context, and the Runtime Dispatch invariant),docs/reference.md,docs/how-to/deferred-dispatch.md, and a comment in the Linear example now say this. None of them says that the handler runs after the acknowledgement.MaxElapsedbound only the backoff sleep, not the HTTP attempts. The Slack package doc, theslackapi.RetryPolicycomment, and theslack.Options.RetryPolicycomment now say this. TheSleepCtxcomment and theinternal/ratelimitREADME drop their ack-window claims.newFirstThoughtDeadlinecomment names itsnow()fallback.Chat.prelude(command and interaction routing) andChat.queuePollInterval(the poll interval and its clamp).Scope
Blast Radius
Readers of the READMEs,
CONTEXT.md, the docs pages, andgo docoutput see corrected text. Nothing compiles differently.Verification
go vet,go test(root, adapters, state, and example modules),go test -raceon the touched packages, andgofmt -lpass on the head commit.Chat.dispatchDeferred,Chat.startDetachedTail, the burst runner,Client.doWithRetry,RetryPolicy.withDefaults), and checked that both tutorial anchors exist.Closes #127
Generated with
xum• Model:anthropic:claude-opus-5-5• Thinking:high