Fix slash review delivery + live progress updates + pre-warm modules cache - #16
Merged
Conversation
The `/nf-core proposals review` slash command delivered the review body over
the slash response URL, which silently drops Block Kit `markdown` blocks (the
ones that render nested bullets) — the review completed but never posted, with
no error. Verified empirically: `markdown` blocks post fine via
`chat.postMessage`, so the failure is response-URL-specific. The auto-trigger
and message shortcut already use `chat.postMessage` and were unaffected.
- Slash command now delivers the review via `chat.postMessage` (markdown
renders reliably there), falling back to DMing the caller when the bot can't
post where the command was run (e.g. a personal self-DM). `preview` goes
privately to the caller's DM. The response URL is used only for the text
ack + progress updates.
- Live progress: a status message updates through the research phases
("Researching nf-core modules… (N checks so far)" → "writing the review…"),
throttled and capped (slash edits an ephemeral message; auto/shortcut update
then delete a thread status message).
- Dockerfile pre-warms the nf-core CLI's clone of nf-core/modules so the first
review on each task skips the ~2-min first-run clone.
- Tests updated for the new slash delivery + DM fallback; added throttling
tests for the progress reporter.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
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.
Why
The
/nf-core proposals reviewslash command was completing reviews but silently not posting them — review ran, Bedrock returned, nothing appeared, no error logged. Root cause: the slash command delivered the review body over the slash response URL, which silently drops Block Kitmarkdownblocks (the ones that render nested bullets, added in the earlier formatting PR).Verified empirically by posting a
markdownblock and asectionblock to a DM viachat.postMessage— both returnedok=Trueand rendered correctly. So themarkdownblock is fine overchat.postMessage; it's only the response-URL surface that drops it. The auto-trigger and message shortcut already usechat.postMessage, so they were never affected.What changed
chat.postMessage(markdown renders reliably there) instead of the response URL. Falls back to DMing the caller when the bot can't post where the command was run (e.g. a personal self-DM).previewgoes privately to the caller's DM with the bot. The response URL is used only for the lightweight text ack + progress updates. Markdown blocks (nested bullets) kept everywhere.🔎 Researching nf-core modules & pipeline overlap… (N checks so far)→✍️ Analysis done — writing the review…. Throttled and capped (slash edits an ephemeral message in place, within the response-URL budget; auto/shortcut post a status message, update it live, then delete it when the real review lands).Dockerfilenow runsnf-core modules list remoteasbotuserso the CLI's clone ofnf-core/modulesis baked into the image; the first review on each task no longer pays the ~2-min first-run clone.chat.postMessagedelivery + a DM-fallback test; 6 new throttling tests for the progress reporter.Testing
ruff check,ruff format --check,mypy src/(only the 2 pre-existingdb/client.pyboto3-stubs errors), and 541 tests pass.🤖 Generated with Claude Code