Skip to content

Deploy Dev reports failure on every successful deploy — and it has made helm rollback dangerous #835

Closed

Description

@lilyshen0722

Every Deploy Dev run on 2026-08-04 reported failure while actually deploying successfully. Three for three:

run ref GH conclusion helm revision actually live?
30898229255 83bf68f failure 420 failed yes
30937612918 2c9bfea failure 421 failed yes
30947763982 8191a2f failure 422 failed yes

All three carry the same helm description:

Upgrade "commonly-dev" failed: client rate limiter Wait returned an error: context deadline exceeded

The rollout itself is fine. After run 30947763982 reported failure, all four deployments were on the intended tag and ready:

backend           …/commonly-backend:8191a2fa    READY 1
frontend          …/commonly-frontend:8191a2fa   READY 1
clawdbot-gateway  …/clawdbot-gateway:8191a2fa    READY 1
commonly-bot      …/commonly-bot:8191a2fa        READY 1

So this is a reporting failure in helm's post-apply wait — the client-side rate limiter times out before the wait completes — not a deployment failure. The failing job is Build + push + helm upgrade.

Why this is worth fixing rather than tolerating

helm rollback is now a loaded gun. Because 420/421/422 are all recorded failed, the newest revision helm considers deployed is 419, from Aug 2. A bare helm rollback commonly-dev during an incident would silently revert three days of production — including the two auth fixes (#817, #821) and the heartbeat opt-in (#833). The operator would be reaching for rollback precisely when they are least likely to check which revision it resolves to.

It trains us to ignore red. Three consecutive false failures in one day is enough to make a real failure invisible. The next genuine deploy break will look exactly like the noise we have learned to dismiss.

Shape of a fix

Likely --wait combined with a kubectl/helm client QPS limit too low for the number of resources in the chart, so the rate limiter's own deadline trips before the resources converge. Worth checking in order:

  1. Raise the helm client burst/QPS (HELM_BURST_LIMIT, default 100) in the deploy workflow — cheapest, and matches the error text.
  2. Confirm --timeout is generous enough that the wait is not racing the limiter.
  3. If the wait remains unreliable, drop --wait and gate the job on an explicit kubectl rollout status per deployment, which reports what we actually care about and gives a truthful exit code.

Whatever the fix, the acceptance test is that a successful deploy exits 0 and leaves a deployed helm revision, so that helm rollback resolves to something from this week.

Activity

  1. lilyshen0722 commented on Aug 4, 2026

    @lilyshen0722
    ContributorAuthor

    Fourth instance, same day — and this one was observed end-to-end while the issue was open.

    Run 30952532468 (ref 9f10aa57, the #817/#821 auth fixes) reported conclusion=failure; helm recorded revision 423 as failed with the identical client rate limiter Wait returned an error: context deadline exceeded. The rollout was nevertheless complete and correct:

    backend           …/commonly-backend:9f10aa57    READY 1
    frontend          …/commonly-frontend:9f10aa57   READY 1
    clawdbot-gateway  …/clawdbot-gateway:9f10aa57    READY 1
    commonly-bot      …/commonly-bot:9f10aa57        READY 1
    

    Confirmed functionally rather than by tag alone: hq-support (not a member) attempted to join a private pod by guessing its exact name and got 403 pod_name_unavailable with the pod's member count unchanged — the #821 behavior, which only exists in this image.

    Timing narrows the cause. All four deployments were already on the new tag and ready well before the workflow gave up, so the failure is entirely in helm's post-apply wait, not in the apply. The rate limiter's deadline expires while it polls resources that have already converged.

    Updated state: revisions 420–423 are all failed, and the newest deployed revision is still 419 (Aug 2). The rollback hazard grows with each deploy — a bare helm rollback now reverts four deploys' worth of changes, including both auth fixes and the heartbeat opt-in.

  2. lilyshen0722 commented on Aug 5, 2026

    @lilyshen0722
    ContributorAuthor

    Verified end-to-end on the next deploy after #839 merged (run 30962598850, ref 7ca09471). Three things had to agree, and did:

    check before after
    workflow conclusion failure ×5 success
    helm revision 420–424 all failed 425 deployed
    live tags correct anyway all four on 7ca09471

    The diagnosis in the report above is wrong, and I want the correction attached to it. I proposed raising HELM_BURST_LIMIT first, because the error reads client rate limiter Wait returned an error. But the release already ran --burst-limit 200 --qps 100 from #245 — that "fix" had been in place for months while failing all day. It was never throttling. It was the context deadline expiring while --wait waited on two workloads that can never become ready: litellm (561 restarts over 2d10h) and cloud-codex-cody (Init:CrashLoopBackOff).

    A rate-limiter error message that is not about rate limiting. Worth remembering before someone re-derives it from the same string.

    Residual — not fixed, not fixable

    Revisions 420–424 stay marked failed in helm history permanently. Those five deploys succeeded; the record says otherwise and cannot be rewritten. Anyone doing archaeology on this window will see five failures that were not, so the correction lives here with the evidence.

    The rollback hazard is resolved going forward — the newest deployed revision is current rather than three days stale — but a rollback explicitly targeting anything in 420–424 still targets a revision helm believes failed.

    Left open deliberately

    litellm.enabled and agents.cloudCodex.enabled are both true in values-dev.yaml while both workloads are dead. Turning them off would have fixed this too, and would stop the wasted scheduling — 561 restarts and counting — but that is a call about the native runtime and the cloud-agent tier, not a CI fix. Doing it to make CI green would have been the right change for the wrong reason.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions