Skip to content

Assignment: enforce concurrency limit when resuming idle work #811

Closed

Description

@DoodleBears

Parent: #81. Related: #194 (Attention acceptance remains separate).

Observable problem

The profile-wide Assignment concurrency limit protects new creation but not resuming an idle Assignment, including Continuity Key reuse. On main 647fbe958f72053c1b85d45cc05996a92603a658, keep one Assignment idle, start three other Assignments, then send a new request to the idle one: four are working despite the default limit of three.

Outcome

All entry points that start an independent Assignment turn enforce the same Host-owned limit. A rejected wake makes no delivery and does not clear its open ask, change model/permission facts, reserve a key, or start a new Session. Requests to an already executing Assignment remain allowed without claiming another slot.

Acceptance

  • Fresh creation, addressed idle/cold wake, and Continuity Key reuse cannot exceed the default three active independent Assignments across PersonaBots.
  • A capacity refusal exposes a structured retryable tool result and explains that no work was started. The Orchestrator can wait or retry after capacity becomes available; there is no queue or background retry.
  • Rejection preserves waiting-human/open-ask state and immutable access/model snapshots. Grant validation continues to fail closed.
  • Already-running updates do not claim another slot; slot reservation is synchronous before crossing into DSH so parallel callers cannot both take the final slot.
  • Focused runtime/adapter tests reproduce the original failure and cover idle/keyed/cross-Bot/available-slot cases.
  • A real isolated DSH path reaches capacity, refuses an idle wake, then successfully resumes the same Assignment after one active turn settles. Include real screenshots or recording in the PR and wait for Human QA.

Boundaries

Reuse the existing Assignment Runtime/Directory and adapter seam. No new scheduler, durable delivery subsystem, or global Settings UI is required for this bounded fix. Safe answer-delivery settlement is a separate sibling issue. No redesign of #194 Attention behavior.

Activity

  1. added this to the v1.0 milestone on Oct 4, 2026
  2. added
    bugSomething isn't working
    ready-for-agentFully specified, ready for an AFK agent
    area:backendHost-side implementation
    feature:assignmentOrchestrator and Assignment collaboration
    scope:tracerHuman-testable implementation slice
    on Oct 4, 2026
  3. DoodleBears commented on Oct 4, 2026

    @DoodleBears
    ContributorAuthor

    Agent work claim

    • Agent: Codex
    • Task: codex/local/01a0f25f-2150-75e3-8895-23d35394b8d8 (not a DSH Session)
    • Issue scope: enforce Assignment capacity on idle/cold addressed wake and Continuity Key reuse; preserve waiting state on refusal; real DSH acceptance and evidence.
    • Branch: codex/811-assignment-capacity
    • Started: 2026-10-04 UTC
    • State: active
  4. added
    agent:activeOne or more coding-agent tasks currently claim this issue; see claim comments for task IDs
    on Oct 4, 2026
  5. DoodleBears commented on Oct 4, 2026

    @DoodleBears
    ContributorAuthor

    Agent work outcome — waiting for Human QA

    • Agent: Codex

    • Task: codex/local/01a0f25f-2150-75e3-8895-23d35394b8d8 (not a DSH Session)

    • State: paused, awaiting Human QA

    • PR: #821, head 356e98f762310b5d67f0d8bba4ec5bd1103b2f46

    • Delivered scope: one Host capacity guard for new work, addressed idle/cold wake and keyed reuse; synchronous reservation before DSH; structured retryable refusal preserving the entire waiting Assignment; running updates use no new slot.

    • Real E2E: baseline grows from three to four working Assignments; fix refuses at three with the question retained; releasing B lets the original A Session complete. Repeated after main integration and cold restart. Four GitHub-rendered screenshots and native Tool/Host proof are in the PR.

    • Local checks: 2,351 integrated full-suite tests passed / 9 skipped; 52 focused tests passed; lint/source policy, formatting, typecheck, bilingual ledgers, build and docs build passed.

    • Remaining: Human QA and explicit merge approval. Answer-delivery settlement remains sibling Assignment: preserve open asks until answer delivery is accepted #812; Assignment Attention: causal dedupe, escalation and recovery acceptance #194 Attention scope is unchanged. No merge was performed.

    • GitHub CI: verification run passed for head 356e98f762310b5d67f0d8bba4ec5bd1103b2f46 (lint, format, typecheck, tests, build, generated artifacts and docs). CodeRabbit reported its review rate limit; no automated review completion is claimed.

  6. added and removed
    ready-for-agentFully specified, ready for an AFK agent
    agent:activeOne or more coding-agent tasks currently claim this issue; see claim comments for task IDs
    on Oct 4, 2026
  7. DoodleBears commented on Oct 4, 2026

    @DoodleBears
    ContributorAuthor

    Human approved merge in task codex/local/01a0f25f-2150-75e3-8895-23d35394b8d8. Resuming the existing claim to resolve current-main integration for #821, verify CI, and merge the approved prerequisite. State: active.

  8. added
    agent:activeOne or more coding-agent tasks currently claim this issue; see claim comments for task IDs
    on Oct 4, 2026
  9. DoodleBears commented on Oct 4, 2026

    @DoodleBears
    ContributorAuthor

    Completed: task codex/local/01a0f25f-2150-75e3-8895-23d35394b8d8 merged Human-approved #821 after current-main integration and exact-head CI passed. Merge commit 91a3a3d. #812 remains the separately scoped answer-delivery follow-up.

  10. removed
    agent:activeOne or more coding-agent tasks currently claim this issue; see claim comments for task IDs
    on Oct 4, 2026
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

    area:backendHost-side implementationbugSomething isn't workingfeature:assignmentOrchestrator and Assignment collaborationready-for-humanRequires human implementationscope:tracerHuman-testable implementation slice

    Type

    No type

    Projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions