Skip to content

improve scheduled work-plan task coverage handling - #60

Merged
pirog merged 1 commit into
mainfrom
pirog-reliable-work-plans
Aug 27, 2026
Merged

improve scheduled work-plan task coverage handling#60
pirog merged 1 commit into
mainfrom
pirog-reliable-work-plans

Conversation

@pirog

@pirog pirog commented Aug 27, 2026

Copy link
Copy Markdown
Owner

Summary

  • add a focused Codex Task Access runbook with the supported list_threads(limit=50) entrypoint,
    bounded recovery, capped-result handling, exact task reads, and a pre-mutation safety boundary
  • simplify the shared automation preflight around recoverable, soft-degradation, and hard-failure
    outcomes while routing GitHub and Codex mechanics to their owning references
  • let Plan Work and Daily Work Plan produce conservative read-only results from partial or unavailable
    Codex commitment coverage without pretending capacity or duplicate coverage is complete
  • preserve Morning Closeout's ability to process exact visible candidates while requiring a fresh
    exact target read immediately before every archival attempt
  • keep GitHub checks connector-first and defer CLI verification until a real fallback or CLI-only
    metadata read is needed

Incident evidence

On 2026-08-27, Daily Work Plan and the unmanaged Vacation Daily Work Plan both authenticated GitHub
successfully through the native connector and direct gh reads. They failed only after first trying
the invalid list_threads(limit=100), correcting to 50, receiving the valid supported maximum with
no cursor, total, or completeness marker, repeating that identical capped result, and hard-stopping
before producing a plan.

Morning Closeout received the same capped listing and completed safely because its owning workflow
treated it as incomplete-but-usable evidence. It retained one dirty, detached, unreferenced worktree
instead of archiving it.

The existing restricted-network GitHub recovery in references/github-read-access.md remains intact
and is now invoked lazily. The implementation also follows OpenAI's current guidance to keep prompts
lean, state instructions once, and define bounded retries and safety boundaries:
https://developers.openai.com/api/docs/guides/latest-model

Behavior and safety

  • recoverable: one caller argument error, transient transport failure, or restricted-network
    ambiguity gets bounded correction or recovery
  • soft degradation: valid capped coverage, incomplete pagination, missing optional metadata, or one
    unavailable optional provider permits only the independent read-only work owned by the caller
  • hard failure: wrong identity, all required providers unavailable after recovery, malformed or
    untrustworthy final data, failed exact target reads before mutation, or ambiguous/destructive target
    safety still stops at the owning boundary
  • partial Plan Work coverage maps only exact visible commitments, reports a visible subtotal and
    unknown remaining/total capacity, and recommends at most one issue
  • unavailable Codex listing with working GitHub discovery may produce at most one clearly conditional
    recommendation and never claims that no active commitment exists
  • later queue/create work requires a fresh trustworthy duplicate check; Morning Closeout requires a
    fresh exact target read before archival

Validation

  • focused manifest and static contract checks: 13 passing
  • Automation, Plan Work, and Morning Closeout skill validators: passed with no warnings
  • bun run automations:validate: passed
  • bun run test: 125 passing
  • bun run lint: passed
  • git diff --check: passed
  • bun run codex:validate: passed

The incident scenarios in test/automation-manifest.spec.js are static prompt/runbook contract checks
plus real manifest composition; they are not a simulation of Codex runtime pagination or archival.
Leia, bun run build, ai:sync, and the installed-cache codex:check / codex:sync / codex:check
cycle were intentionally skipped because this change does not authorize those mutation or release
surfaces.

Risk and tradeoff

Partial task coverage can still hide an existing commitment. The design makes that uncertainty
visible, limits degraded recommendations to one issue, refuses exact capacity arithmetic, and blocks
later task creation until stronger duplicate verification succeeds. This trades plan completeness for
a useful conditional result without weakening mutation safety.

Vacation Daily Work Plan follow-up

Vacation Daily Work Plan is intentionally unmanaged and is not added to AUTOMATIONS.yaml or changed
by this PR. After merge and an approved cache sync, its live prompt needs a separately approved update
to use the same simplified preflight and Codex Task Access behavior.

@netlify

netlify Bot commented Aug 27, 2026

Copy link
Copy Markdown

Deploy Preview for pirog-boot-me ready!

Name Link
🔨 Latest commit e1c5ba1
🔍 Latest deploy log https://app.netlify.com/projects/pirog-boot-me/deploys/6a905ea2cd6d710008fd6216
😎 Deploy Preview https://deploy-preview-60--pirog-boot-me.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@pirog
pirog merged commit 2f3c884 into main Aug 27, 2026
13 checks passed
@pirog
pirog deleted the pirog-reliable-work-plans branch August 27, 2026 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant