feat: route different notifications to different channels - #42
feat: route different notifications to different channels#42adamrtalbot wants to merge 9 commits into
Conversation
Generated by Claude Code
Code ReviewSummary: Per-event channel routing implementation is solid. Code changes are clean and well-tested. Critical IssuesBLOCKING: Documentation is missing The feature is not documented anywhere users will find it:
Tests✅ Tests are included and comprehensive:
UX✅ User experience is intuitive:
Minor Notes
Action Required: Add documentation before merging. Once docs are updated, this is ready to ship. |
Generated by Claude Code
Review: Per-Event Channel Routing✅ Documentation: Comprehensive and well-structured
✅ Examples: Complete
✅ Tests: Sufficient coverage
✅ UX: Clean and intuitive
Minor note: The threading logic in shouldUseThread() compares event channel to bot channel, which correctly handles the case where events go to different channels. File uploads will also respect threading correctly since threadTs is conditionally set. Approval: This PR is ready to merge. |
|
@claude merge from main and fix any merge conflicts. |
|
Claude finished @adamrtalbot's task in 4s —— View job Merge from main completed ✓I've manually merged What was brought in from main (v0.5.1)New features:
Per-event channel routing (this PR, preserved)
Tests updated
|
Manually merged origin/main (v0.5.1) into this branch since both share no common ancestor (main was squash-merged). This commit brings in all features added since v0.4.0 while preserving the per-event channel routing feature introduced by this PR. New features from main (v0.5.1): - Progress tracking with configurable update interval (OnProgressConfig) - Emoji reactions on start/success/error (ReactionsConfig) - Seqera Platform deep-link button in start message (SeqeraPlatformConfig) - includeFields filter on all event configs (onStart/onComplete/onError) - validateOnStartup option with auth.test API check - chat.update support for editing messages in-place - Reactions API (addReaction / removeReaction) in BotSlackSender - Cancelled workflow handling (skips notifications, cleans up reactions) Per-event channel routing (this PR, preserved): - channel field on OnStartConfig, OnCompleteConfig, OnErrorConfig - channelOverride parameter on SlackMessageBuilder build methods - shouldUseThread() logic in SlackObserver to skip threading when routing to a different channel - Validation of per-event channel format in SlackConfig Build updated to plugin version 1.0.0-beta.12. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
@claude I'm still seeing merge conflicts, can you fix them? |
|
Claude finished @adamrtalbot's task in 18m 15s —— View job Merge Conflicts Fixed ✓
Root cause: The previous merge (commit Fix: Created a proper merge commit ( Since Note: There are two minor cleanup commits ( |
Establishes origin/main (c253a54) as a parent commit to resolve GitHub's merge conflict indicator. The branch already contains all of main's v0.5.1 content plus the per-event channel routing feature. This merge commit properly records that ancestry in the git history. Co-authored-by: Adam Talbot <adamrtalbot@users.noreply.github.com>
Establishes origin/main (c253a54) as a parent commit to resolve GitHub's merge conflict indicator. The branch already contains all of main's v0.5.1 content plus the per-event channel routing feature. This merge commit properly records that ancestry in the git history. Co-authored-by: Adam Talbot <adamrtalbot@users.noreply.github.com>
Code ReviewOverall the feature is well-structured and the core routing logic is clean. A few issues need attention before merge. BugsVersion regression in examples and CONTRIBUTING.md
This looks like a copy-paste error; the version should not regress. New example uses unversioned plugin ID Breaking Change (Unannounced)
Tests — Missing Coverage
The existing observer tests capture that the correct channel is passed, but not that threading is actually suppressed when the channel differs. Documentation / ExamplesEverything else looks good — the guide section, API reference table updates, and |
Code ReviewIssues1. Version regression in docs and examples — 2. Threading bug when
onStart { channel = '#deployments' } // threadTs stored from #deployments
onComplete { } // channel = null → shouldUseThread(null) → true
The comparison should be 3. Example 13 uses What's Good
Blocking: the threading bug (#2) and version regression (#1) should be addressed before merge. |
Compare threading against effective start channel, restore plugin version in examples/docs, version example 13 config, and add shouldUseThread tests. Generated by Codex Co-authored-by: Cursor <cursoragent@cursor.com>
|
Addressed the latest Claude review in fd7621c:
|
Summary
Adds per-event channel routing so start, complete, and error notifications can be sent to different Slack channels, addressing #37.
Changes
channelfield (String, default: null for global channel)createMessagePayload()andbuildWorkflow*Message()methods to accept channel overrideConfiguration
slack { bot { token = 'xoxb-...' channel = '#general' // global default channel } onStart { channel = '#deployments' // override for start notifications } onComplete { channel = '#results' // override for completion notifications } onError { channel = '#alerts' // override for error notifications } }Notes
bot.channelCloses #37