Skip to content

release: agentcairn 0.24.2 Codex hook hotfix#130

Merged
ccf merged 2 commits into
mainfrom
agent/fix-codex-hook-command
Jul 12, 2026
Merged

release: agentcairn 0.24.2 Codex hook hotfix#130
ccf merged 2 commits into
mainfrom
agent/fix-codex-hook-command

Conversation

@ccf

@ccf ccf commented Jul 12, 2026

Copy link
Copy Markdown
Owner

Summary

Ships agentcairn 0.24.2 and Codex plugin 0.1.2 with the SessionStart/SessionEnd dispatch fix.

  • Encodes each Codex command hook as the documented single command string.
  • Removes the unsupported separate args arrays.
  • Adds static and execution-level regression coverage for the Codex handler shape.
  • Bumps the package release to 0.24.2 and the Codex plugin to 0.1.2.

Root cause

hooks.codex.json declared each handler as command: "sh" plus a separate args array. Codex command hooks execute the command string and do not dispatch that separate array. The result was bare sh receiving the SessionStart JSON on stdin, interpreting the JSON as a shell command, and exiting with code 127.

Impact

Fresh Codex sessions no longer show SessionStart hook (failed): hook exited with code 127. SessionEnd uses the same corrected dispatch shape. The scripts themselves and their failure-tolerant behavior are unchanged.

Verification

  • Full suite: 744 passed, 5 skipped
  • Plugin suite: 25 passed
  • Ruff format and lint: passed
  • Pre-commit suite: passed
  • Installed cache-busted plugin 0.1.2: exact SessionStart and SessionEnd handlers exit 0
  • Real local SessionStart script: exits 0
  • AgentCairn live vault doctor: OK
  • MCP remember/recall write-through: verified
  • Clean git-archive build: 137 KB wheel, 1.7 MB sdist
  • Built wheel reports 0.24.2

Local shellcheck was unavailable; the plugin workflow installs and runs it in CI.

Release

After merge, tag v0.24.2. The tag workflow publishes the wheel and sdist to PyPI; then create the GitHub Release from the 0.24.2 changelog entry and reinstall/dogfood the released artifacts.


Note

Low Risk
Plugin hook JSON and version/changelog only; no changes to core memory, auth, or vault logic.

Overview
Releases agentcairn 0.24.2 and the Codex plugin 0.1.2 with a hotfix for broken SessionStart/SessionEnd hooks.

Codex command hooks only run the documented command string; separate args were ignored, so handlers ran bare sh with hook JSON on stdin and failed with exit 127. hooks.codex.json now uses one string per event, e.g. /bin/sh "${PLUGIN_ROOT}/scripts/session-start.sh" (same for session-end); hook scripts are unchanged.

Tests assert the handler shape (no args) and that the SessionStart command actually executes the script with JSON on stdin. Changelog and version bumps cover the package and Codex plugin manifest.

Reviewed by Cursor Bugbot for commit b8e0edd. Bugbot is set up for automated code reviews on this repo. Configure here.

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
agentcairn b8e0edd Commit Preview URL

Branch Preview URL
Jul 12 2026, 10:56 PM

@ccf
ccf marked this pull request as ready for review July 12, 2026 23:37
@ccf
ccf merged commit 6d0ea3c into main Jul 12, 2026
8 checks passed
@ccf
ccf deleted the agent/fix-codex-hook-command branch July 15, 2026 19:51
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