githubnext / githubnext/gh-aw-cao
[cao-evolution:efficiency] Control-plane efficiency requires attention
- Dominant language
- JavaScript
- Stars
- 3
- Forks
- 1
- Avg merge
- 49m
- Merged PRs (30d)
- 837
Description
Self-care package's orchestrator is failing on nearly every scheduled run this week, wasting AI Credits and API calls with zero usable review output.
**Action:** Maintainer (control-repo owner) should assign this issue to Copilot to fix the missing `/tmp/gh-aw/actions/otlp.cjs` reference in the self-care dispatcher step; acceptance check: next 20 scheduled `self-care.lock.yml` runs show `agent` job conclusion = success (or at least no `Cannot find module` error), matching the success rate of sibling orchestrators (>85%).
**Package health baseline (last 7 days, ending 2026-09-16 01:00 UTC, githubnext/gh-aw-cao):**
- `self-care` orchestrator (`self-care.lock.yml`): 423 runs, 301 failures (71%), 122 successes — every run in the current 124-run streak (as of run ``#857``) has failed.
- Comparison window (7–14 days prior): 377 runs, 62 failures (16%), 314 successes. Failure rate roughly quadrupled week-over-week.
- Root cause (confirmed from job logs, e.g. run 35042044893, job `agent`): `Error: Cannot find module '/tmp/gh-aw/actions/otlp.cjs'` thrown by the `actions/github-script` dispatcher-telemetry step that runs after the agent step on orchestrator runs. This is a structural/runtime bug (missing file at execution time), not a policy denial, rate limit, or model/turn issue — it is out of scope for `AW Optimization`.
- For comparison, sibling package orchestrators in the same window succeeded overwhelmingly: `cao-evolution` orchestrator 107/117 success (91%), `optimization` orchestrator 91/100 (91%), `eslint-rules` orchestrator 11/11 (100%), `repo-assist` orchestrator 2/2 (100%). This isolates the defect to the self-care dispatcher path specifically.
**Expected improvement:** Restoring self-care orchestrator success from ~29% to the sibling-package baseline (~90%+) removes roughly 300 wasted scheduled runs per week — comfortably over the required 10% improvement threshold in run-failure rate, while preserving all existing dispatch/authority/coverage behavior (this is a bug fix to a telemetry helper script, not a policy or scope change).
**Verification metric:** `agent` job success rate for `.github/workflows/self-care.lock.yml` scheduled runs over the next complete 7-day window, queried the same way as this report (via `actions_list`/`list_workflow_runs` or the `cao` activity cache once repopulated).
**Safety invariant preserved:** No change to admission, target authority, review routing, exact-SHA policy resolution, credential separation, or fail-closed behavior — this is a bug in a post-agent OTEL dispatcher-telemetry script, unrelated to control-plane policy.
Agent prompt
The self-care package orchestrator workflow (`.github/workflows/self-care.lock.yml`, compiled from its Markdown source) fails almost every run with:
```
Error: Cannot find module '/tmp/gh-aw/actions/otlp.cjs'
Require stack:
- /home/runner/work/_actions/actions/github-script/3a2844b7e9c422d3c10d287c895573f7108da1b3/dist/index.js
```
This happens in an `actions/github-script` step that runs after the `agent` step, in a post-agent dispatcher-telemetry block that does `require('/tmp/gh-aw/actions/otlp.cjs')` and logs a `central-agentic-ops.dispatcher` OTEL span. The same dispatcher-telemetry pattern exists for other package orchestrators (e.g. `cao-evolution.lock.yml`, `optimization.lock.yml`), which are NOT failing — compare their generated step definitions and shared source (likely under `.github/workflows/shared/control.md` or a related shared script/include) to find why `self-care`'s workflow ends up missing the `/tmp/gh-aw/actions/otlp.cjs` file at that point in the job (e.g. a workflow-source difference in step ordering, a missing artifact/setup step, or an outdated compiled lock file).
Scope:
1. Locate the editable Markdown source for `self-care.lock.yml` (likely `.github/workflows/self-care.md` or similar) and the shared control/dispatcher script it imports.
2. Compare against a working orchestrator (e.g. `cao-evolution.md`) to find the structural difference causing the missing `otlp.cjs` file only for self-care.
3. Fix the self-care workflow source (not the generated lock file) so the OTEL dispatcher-telemetry step can find `/tmp/gh-aw/actions/otlp.cjs`, or otherwise fixes whatever setup step is supposed to place that file before this step runs.
4. Run `npm run compile` (or `npm run compile:locks` if lock files must be regenerated) to verify the workflow compiles cleanly, and confirm the regenerated lock file diff only affects `self-care.lock.yml` (and any shared file actually changed).
5. Do not modify unrelated packages or policy.
Validation: `gh aw compile` succeeds with no diff to `.lock.yml` files for unrelated packages; the corrected `self-care.lock.yml` no longer contains a dispatcher step requiring a module at a path that doesn't exist by that point in the job (verify by inspecting the compiled YAML's step order/setup, since we cannot execute Actions runs directly from this task).
Query evidence
Data source: read-only GitHub Actions API (`actions_list` method `list_workflow_runs`, `list_workflow_jobs`; `get_job_logs`) against `githubnext/gh-aw-cao`, since the shared activity cache (`$RUNNER_TEMP/cao-activity/gh-aw-logs.sqlite` and shard JSONL files) was not present in this run (cache miss — fell back to bounded direct GitHub reads scoped to this control repository only).
Workflow → run counts (last ~4–5 days of history available via API, current 7-day window):
| Workflow | Runs (7d) | Success | Failure | Other |
|---|---|---|---|---|
| self-care.lock.yml (orchestrator) | 423 | 122 | 301 | 0 |
| cao-evolution.lock.yml (orchestrator) | 117 | 107 | 9 | 1 cancelled |
| optimization.lock.yml (orchestrator) | 100 | 91 | 9 | 0 |
| eslint-rules.lock.yml (orchestrator) | 11 | 11 | 0 | 0 |
| repo-assist.lock.yml (orchestrator) | 2 | 2 | 0 | 0 |
| optimization-ai-credit-optimizer (worker) | 100 | 24 | 75 | 1 queued |
| optimization-ai-credit-auditor (worker) | 100 | 60 | 36 | 4 in-progress |
Two other elevated-failure workers were observed (`optimization-ai-credit-optimizer` 75% failure, `optimization-ai-credit-auditor` 36% failure) but their failures trace to GitHub App installation/token-minting errors (`Not Found - .../apps#get-a-repository-installation-for-the-authenticated-app`) when dispatched against specific target repos (e.g. `github/gh-aw-mcpg`), which is a credential/target-repo-scoping concern for the `optimization` package (out of scope for this issue and potentially already tracked/owned by that package's own health signals) rather than a `self-care`-specific structural bug. This report focuses on the single highest-confidence, highest-magnitude, structurally-clear finding: the self-care orchestrator's `otlp.cjs` module error.
### Control Plane
- Correlation ID: 35042018227-117
- Central repository: githubnext/gh-aw-cao
- Control plane run URL: https://github.com/githubnext/gh-aw-cao/actions/runs/35042018227
> Generated by [CAO Evolution / Efficiency](https://github.com/githubnext/gh-aw-cao/actions/runs/35042570047) · copilot · auto · 185.9 AIC · ⌖ 9.26 AIC · ⊞ 14K · [◷](https://github.com/search?q=repo%3Agithubnext%2Fgh-aw-cao+is%3Aissue+%22gh-aw-workflow-call-id%3A+githubnext%2Fgh-aw-cao%2Fcao-evolution-efficiency%22&type=issues)
> - [x] expires on Sep 30, 2026, 1:17 AM UTC
Contributor guide
Research direction
Start with .github/workflows/self-care.md or its source equivalent and compare the generated self-care.lock.yml with cao-evolution.lock.yml, focusing on the dispatcher-telemetry step and /tmp/gh-aw/actions/otlp.cjs setup. Inspect shared control sources such as .github/workflows/shared/control.md, then run npm run compile or npm run compile:locks. Done means compilation succeeds, the self-care workflow no longer references a missing module at that step, and unrelated lock files are unchanged.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, javascript
- Domain
- ci-cd, devops
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 72/100