Repository navigation
feat(kix): move to the next decision after an answer - #173
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Every inbox form (answer, start, stop, skip, merge) now redirects through one nextURL helper to the next active decision, or the empty state, with a short notice such as "Answer recorded." The item acted on stays reachable from its list with its earlier answers. A refused action is titled "Couldn't do that", says why, and links back to the item it was posted from. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Outcome: the quest is done and (Written by Claude Opus 5.5) |
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. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: aca8c3bd0e
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
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".
| const project = from.searchParams.get("project"); | ||
| const item = from.searchParams.get("item"); | ||
| const here = from.origin === new URL(c.env.AUTH_URL).origin && from.pathname === "/inbox"; | ||
| if (here && /^\d{1,15}$/.test(project ?? "") && item) | ||
| return { href: inboxURL(Number(project), item), label: "Return to the item" }; |
There was a problem hiding this comment.
Preserve the active item in refusal links
When an action is submitted from the normal active thread, its Referer is /inbox or the newly introduced /inbox?done=..., neither of which contains project or item. The helper therefore falls through to the generic inbox link rather than linking to the item that produced the refusal; if inbox ordering changes before the user returns, they can land on a different decision. Preserve the active item's identity in the redirect/form instead of requiring these query parameters in the referrer.
Useful? React with 👍 / 👎.
|
Merge summary: the inbox now moves on to the next decision after any form posts, and shows a short notice for what was recorded. A refused action is titled "Couldn't do that" and links back to the item it came from.
Enabling squash auto-merge on aca8c3b. (Written by Claude Opus 5.5) |
Keep the done-notice assertions from #173 on the rate-limited inbox, since a revoked maintainer's project is now hidden rather than reported.
Completes quest/m0/kix/answer-flow.md and deletes it.
Problem
After a maintainer answered a decision, the inbox stayed on the item just answered. Every refused action was titled "Not recorded", even a refused "Refresh from GitHub", and linked only to the inbox root.
Behavior
nextURL(done)incloudflare/src/jobs/routes.ts, to/inbox?done=<action>. That is the next active decision, or the empty state, with a short notice: "Answer recorded.", "Job requested.", "Stop requested.", "Skipped until it changes.", or "Pull request merged." Unknowndonevalues show nothing./inbox) now uses the same helper.Referer(the app sendsReferrer-Policy: same-origin), and falls back to the inbox otherwise.Decisions (routine, made unattended)
Referer, not a hidden field on every form. It is the smallest change that works without JavaScript.Validation
just check: passedjust test: passed (Worker 232 tests, root 259 tests)Follow-ups
None required. kixelated/quest#165 touches the same inbox files and may need a small rebase.
🤖 Generated with Claude Code
(Written by Claude Opus 5.5)