fix(roadmap-emit): soft-fail 400 unknown-channel like 404 unknown-slug#126
Merged
Conversation
When PR #125 introduced `rc` as a first-class ChannelName variant and updated CHANNEL_MAP to route rc → channel:'rc', the tray-v1.8.9-rc.1 release tag fired the emit script against a production server still running v1.8.9 (pre-#125), which rejected `channel: 'rc'` with 400 "UnknownChannel: rc". The non-retryable-4xx fatal path then exit-1'd, blocking the release workflow. Mirror the existing 404-on-unknown-slug pattern: if the server returns 400 AND the response text matches /unknown.*channel/i, treat as a soft failure and exit 0. Same root cause class as 404 (config / rollout-order chicken-and-egg between client + server); same disposition (the release artifacts are fine, telemetry is optional, unblock the workflow). The regex is deliberately narrow — only matches "unknown" adjacent to "channel" in the body — so other 400s (auth, bad payload, schema mismatch) still hard-fail per existing behaviour. Behavioral tests in this branch's worktree confirmed both paths: - 400 + "UnknownChannel: rc" body → soft-fail, exit 0 - 400 + "malformed payload" body → hard-fail, exit 1 Surfaced on tray-v1.8.9-rc.1 (run 26532296011). Live emit was unaffected because channel:'live' has been valid on the server for all relevant versions; rc is the only channel that just gained server-side support and not yet deployed.
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.
Summary
scripts/roadmap-emit-event.mjs, mirroring the existing 404-soft-fail-on-unknown-slug pattern.Why
PR #125 promoted
rcto a first-class ChannelName variant in both the server (ChannelName::Rc) and the client (CHANNEL_MAP['rc'] → channel:'rc'). Server + client landed simultaneously onnext. But the rollout pipeline is:next→ auto-alpha → tags fire → emit script POSTs to production serverchannel: 'rc'→ 400 UnknownChannel → fatal → workflow failsThat broke
tray-v1.8.9-rc.1(run 26532296011): tray installer + GitHub Release published fine, but the emit step exit-1'd, which also blocked the Auto-publish roadmap changelog (Live only) job from running.The pattern is identical to the 404-soft-fail logic shipped in PR #88: telemetry hop is best-effort, a rollout-order gap shouldn't block the release. So apply the same disposition to its mirror image.
What does NOT change
livehas been valid for all server versions./unknown.*channel/iwon't match them.Test plan
[roadmap-emit] soft-fail 400 unknown-channellog linenode -c scripts/roadmap-emit-event.mjs(syntax check)gh run rerun --job 78154339617and confirm it now soft-fails cleanly OR succeeds (depending on whether production server has been bumped by then)Pairs with PR #125 (rc as first-class channel). Should land on the same alpha → beta → rc → live cycle that #125 went through.