Skip to content

kurt init installs PreToolUse and PostToolUse hooks in .claude/settings.json that send HTTP requests to the Kurt web API #95

Description

@dkrevitt

For every Edit/Write/Update tool call. These hooks are intended for the approval workflow in the Kurt web UI, but they fire in
all Claude Code sessions — including regular terminal usage where kurt serve isn't running.

Each hook call hangs waiting for a response that
never comes, causing two blocking HTTP requests per tool use that stack up and burn CPU/memory.

Potential fix: Adding a guard ([ -z "$KURT_SESSION_PROVIDER" ] && exit 0) to the PreToolUse and PostToolUse hook commands. The Kurt web UI already sets KURT_SESSION_PROVIDER when spawning Code Sessions, so the hooks now no-op immediately in standalone terminal sessions while continuing to work as intended when launched from the web UI.

Files to change:

  • src/kurt/agents/claude-settings.json (template for future kurt init)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions