Skip to content

fix: wait for actual Claude response - #1

Open
JamesW546 wants to merge 1 commit into
weidwonder:mainfrom
JamesW546:fix/verify-assistant-response
Open

JamesW546 wants to merge 1 commit into
weidwonder:mainfrom
JamesW546:fix/verify-assistant-response

Conversation

@JamesW546

Copy link
Copy Markdown

Summary

  • ignore hook and system lifecycle events instead of treating them as successful responses
  • require a real AssistantMessage followed by a successful ResultMessage
  • isolate the wake-up request from user/project hooks, MCP servers, and CLAUDE.md settings

Problem

The previous string-based check treated HookEventMessage as success because its class name does not contain SystemMessage, even though it is a system lifecycle event. The function then returned before Claude produced an assistant response, causing false-positive wake-up logs.

Verification

  • python -m py_compile waker.py
  • manual wake-up request completed with AssistantMessage
  • scheduled cron run completed with a real user -> assistant session

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