Repository navigation
Description
Summary
Potential flake in the Kind E2E learning failover spec: prompt submission fails with HTTP 500 before the test reaches attempt-claim verification or pod replacement. An earlier run passed with unchanged deployed application/test source and Kind task. The intermittent behavior is established across those runs; the cause of the HTTP 500 remains unknown.
Assigned to @jbeda for investigation in a separate session.
Evidence
- Failed job at PR build: make ordinary validation workspace-first #2911 head
6f9ab48fbaf697e925258f3cea57e97e36223cd1: https://github.com/stacklok/mecatl/actions/runs/44791631150/job/136480665263 - Earlier successful Kind job at
7ac1f5c3b5e1f78a911be4f600305335d9d7029c: https://github.com/stacklok/mecatl/actions/runs/44786646865/job/136463153817 - Changes between these revisions are documentation, a publication-workflow comment, and script-test changes; deployed Go code, chart, and Kind task are unchanged.
- Spec:
remote learning worker failover / recovers one claimed attempt and serves the activated skill from a replacement pod. - Random seed:
1795198876. - Failure:
e2e/k8s/learning_failover_test.go:78, after 30.001 seconds. Last observed prompt HTTP status was 500; expected 200. - Session creation succeeded. The agent pod was Running and Ready with zero restarts. The spec failed before testing learning claim recovery.
- Suite result: 23 passed, 1 failed, 3 skipped.
Diagnostic gap
The assertion at e2e/k8s/learning_failover_test.go:79 passes formatBody(responseBody) as a message argument. It is evaluated before Should starts polling, so it captures the initially empty body. The blank prompt response: in the failure does not establish that the server returned an empty response.
The failure artifact (k8s-e2e-artifacts-44791631150) contains the same test output, without server logs. deferLearningDiagnostics records only pod status; cleanup restores the baseline deployment and later deletes the cluster. The underlying server error cannot be recovered from the retained artifact.
Investigation
- Make the failure message evaluate the final response body after polling, retaining the existing bounded formatting.
- Reproduce or rerun the Kind job with existing timeouts and inspect the actual HTTP error. Retain bounded, appropriately redacted server diagnostics if needed.
- The existing retry comment mentions lease-acquisition timeouts, but that is not evidence of the cause in this run. Determine whether this is fixture/infrastructure timing or an intermittent application failure.
- Fix the identified cause rather than increasing timeouts or adding blanket retries without evidence.
Completion: explain the intermittent prompt-admission failure and address its cause, with usable diagnostics if it recurs.
Activity