Skip to content

Matrix-launched opencode sessions not registered in daemon state #151

@c-h-

Description

@c-h-

Bug

Sessions launched via agentctl launch --matrix are tracked in ~/.agentctl/opencode-sessions/ (wrapper scripts, .json metadata, .exit files) but are never registered in state.json.

This means:

  • agentctl list never shows them
  • agentctl status <id> returns 'Session not found'
  • No lifecycle fuse is created
  • No webhook fires on completion
  • The supervisor pipeline never triggers

Evidence

# Sessions exist on disk:
ls ~/.agentctl/opencode-sessions/682870d7*.{json,exit,sh}  # all present

# But not in state:
agentctl status 682870d7  # Session not found
jq '.sessions[] | select(.id | startswith("682870"))' ~/.agentctl/state.json  # empty

Impact

This breaks the entire completion callback pipeline. Matrix-launched sessions run to completion but no downstream automation fires (webhooks, OrgLoop supervisor routes, etc.).

Expected

Matrix-launched sessions should be registered in daemon state just like single agentctl launch sessions.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions