Skip to content
This repository was archived by the owner on Oct 9, 2026. It is now read-only.
This repository was archived by the owner on Oct 9, 2026. It is now read-only.

Plugin lifecycle hooks for workspace preparation and quality providers #149

Description

@shiny-code-bot

Intent

Make Codex Lab plugin hooks sufficient for optional domain integrations like Odoo devkit workspace preparation plus JetBrains/PyCharm quality inspection, without baking Odoo or JetBrains logic into the coding harness.

Current Status

State: waiting for post-convergence product sequencing. Existing workspace/quality-provider consumer proofs remain recorded; generic detect/prepare, typed handoff and cleanup/lease lifecycle remain unfinished.

#926's PostToolUse/Stop validation proposal is retained as an open packaging option. Any selected hook must preserve typed terminal outcomes, bounded correction, complete relevant instructions, command selection, cancellation and truthful pending/completed behavior. Async hooks do not supply synchronous control effects. #231 owns Background Review lifecycle; #785 owns installed functional validation defaults.

Next action when promoted: select one concrete consumer-backed generic slice after #927/#928 and protected #787 work. No hook replacement or source change is authorized by research absorption. No native issue blocker; parked on roadmap priority. Last verified: September 16, 2026.

Required Hooks And Contracts

  • Workspace lifecycle hooks: after worktree/materialization/session start, plus workspace detect/prepare phases.
  • Quality lifecycle hooks: quality prepare/run/closeout with normalized clean/findings/inconclusive/skipped results.
  • Structured artifact handoff: per-session plugin artifact directory and typed descriptor outputs usable by later hooks/plugins.
  • Cleanup lifecycle: best-effort cleanup hook after stop/failure/timeout for provider leases and temporary resources.
  • Hook inputs should expose cwd, repo root, worktree root, main worktree when known, branch/head, and project markers.
  • Capability discovery for providers such as workspace.prepare.odoo-devkit and quality.ideInspection.jetbrains.
  • Exec-harness coverage for descriptor handoff, blocking results, and cleanup behavior.

Acceptance Criteria

  • An Odoo plugin can detect workspace.toml, run odoo-devkit workspace sync for the active worktree, and emit a descriptor without Codex Lab core understanding Odoo.
  • A JetBrains inspection plugin can consume that descriptor during quality closeout and block/report findings without Codex Lab core understanding JetBrains or PyCharm.
  • Plugins can pass artifacts across lifecycle phases using a documented contract rather than ad hoc files.
  • Cleanup hooks run sufficiently for provider leases/temp resources.
  • Existing prompt/tool/stop hooks continue to work.

Out Of Scope

  • Implementing Odoo-specific workspace generation in Codex Lab core.
  • Implementing JetBrains inspection execution in Codex Lab core.
  • Making Launchplane depend on local IDE state.

Activity

  1. added
    planDurable planning issue
    plan:waitingDurable plan parked pending a decision, event, or non-issue condition; not for PR QA
    on Jun 20, 2026
  2. cbusillo commented on Jun 21, 2026

    @cbusillo
    Owner

    Direction checkpoint from the JetBrains/Odoo inspection planning thread:

    Do not push more Odoo/JetBrains orchestration into jetbrains-inspection-api or the helper first. The WebStorm false-green/red-lane foundation is now complete upstream, and the remaining Odoo-aware inspection work should wait for Codex Lab to stabilize enough to host the generic lifecycle surface.

    When this issue becomes actionable, the needed Codex Lab surface is likely broader than hooks alone:

    • hooks for workspace detect/prepare, quality prepare/run/closeout, and cleanup;
    • commands/CLI entrypoints so agents and tests can invoke those phases deterministically outside a full chat session;
    • endpoints or local control surfaces, if Codex Lab runtime needs external tools/plugins to report provider state, descriptors, readiness, or cleanup results;
    • typed artifact/descriptor handoff between phases so odoo-devkit can prepare a per-worktree IDE workspace and jetbrains-inspection can consume it without Codex Lab core understanding either Odoo or JetBrains;
    • exec-harness scenarios proving descriptor handoff, blocking quality results, skipped/inconclusive states, and cleanup behavior.

    This keeps the dependency direction clean:

    1. Codex Lab provides generic lifecycle/artifact/quality-provider orchestration.
    2. odoo-devkit emits the Odoo workspace descriptor for the active worktree.
    3. jetbrains-inspection consumes the descriptor and runs PyCharm/Odoo-aware inspections.
    4. jetbrains-inspection-api stays generic unless a truly generic IDE capability endpoint is required.
  3. cbusillo commented on Jul 1, 2026

    @cbusillo
    Owner

    Planning update from #232 on July 1, 2026:

    The feature ownership matrix now classifies plugins/skills/hooks as the convergence path for optional domain behavior. Core should keep generic plugin/skill/hook substrate and trust policy; domain behavior such as workspace prep, IDE inspection, Code Bridge setup, and agent role packs should move into plugins/skills/hooks where possible.

    Next #149 work should focus on generic plugin-packaged skills/hooks and lifecycle artifact handoff, not Odoo/JetBrains-specific logic in core. See #232 Current Status for the durable matrix rows.

  4. added
    plan:activePlan is actionable now
    and removed
    plan:waitingDurable plan parked pending a decision, event, or non-issue condition; not for PR QA
    on Jul 2, 2026
  5. added
    plan:waitingDurable plan parked pending a decision, event, or non-issue condition; not for PR QA
    and removed
    plan:activePlan is actionable now
    on Jul 10, 2026
  6. added
    plan:donePlan completed or superseded
    and removed
    plan:waitingDurable plan parked pending a decision, event, or non-issue condition; not for PR QA
    on Sep 27, 2026
  7. shiny-code-app commented on Sep 27, 2026

    @shiny-code-app

    Backlog reconciliation — 2026-09-26

    Owner decision, 2026-09-26: move this to the shared catalog. DIRECTION.md says skills and hooks live in the shared catalog, and upstream Codex already ships hook events (codex-rs/hooks). The work continues in cbusillo/codex-skills#827, which records the owner's dependency order from the 2026-06-21 and 2026-07-01 comments above. A codex-lab issue comes back only if a specific hook event is missing upstream and no sidecar can cover it.

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

    planDurable planning issueplan:donePlan completed or superseded

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions