Skip to content

id: implement: demo library + app importing a platform-capability dependency, with both negative tests #5957

Closed

Description

@dezren39

Part of the worlds design program: #5955. Statements S5–S7 of the 2026-11-04 brief.

Task (Drew, in substance)

Find — or build — a demo library and a demo app demonstrating the Roc library import model for worlds:

  • The demo library relies on platform capabilities, so it is technically not pure.
  • The demo app imports that library and uses it successfully on a platform that provides those capabilities.
  • Existing starting points: pkgs/id/examples/{roc-world,roc-chat,roc-counter,roc-grid,roc-screen} (the roc-world example already carries the capability protocol helpers in RocCap.roc). Prefer extending an existing example's pattern over inventing a parallel one.

Acceptance criteria — BOTH negative tests are required

  1. Negative test A (capability not on the platform): a variant of the demo app (or the same app compiled against a reduced platform) that tries to use something that is not on the platform must fail — compile-time failure preferred; if the failure is at load/admission time instead, the test must pin exactly that behavior and say why.
  2. Negative test B (platform used wrong): a variant that imports the platform and tries to use it wrong (wrong signature, wrong protocol order, malformed capability request) must fail as a test.
  3. The positive path (app + platform-dependent library on a sufficient platform) passes and runs.
  4. All three cases are wired into the repo's normal test flow so they cannot silently rot — this is also a down payment on the Phase 9–10 Roc-library verification debt in #796 (cf. the closed #813: roc test was never wired into CI for library code).

Related

  • Import model design (filed alongside this task under #5955)
  • Capability catalog: pkgs/id/crates/id-core/src/world_caps.rs
  • Core/app platform design: #2028

Done looks like

Demo library + app in the tree, both negative tests running in CI/test flow and failing for the right reason (asserted error, not just any failure), positive path green.

Activity

  1. added
    kind/featureNew feature or capability request
    priority/normalOrdinary priority (the default)
    app/idPackage/app: id (pkgs/ or apps/ in this repo)
    on Nov 5, 2026
  2. developing-today commented on Nov 5, 2026

    @developing-today
    Contributor
  3. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    Ruling — C2 capability posture, demo implications (Drew, 2026-11-04 23:57 CST; primary record on #5958).

    The earlier working interpretation — that the fs/network posture of tonight's brief supersedes the shipped default — is corrected: the default stays the current completely isolated seccomp policy. For this demo:

    • The negative tests stand against the default isolated posture (capability not on the platform → fails; platform imported + used wrong → fails).
    • If the demo exercises file/network capabilities, it does so as the new opt-in tier: off by default on servers, publishing first-party only for now, but built so it could be enabled for anyone later (general enablement is a future, testing-gated decision).
  4. added
    queue/queuedHas a queued task in the Supabase agent queue
    task/triageQueue packet kind: verify, reproduce, and route this item
    work/assignedQueue worker lifecycle state
    queue/claimedQueue worker lifecycle state
    and removed
    queue/queuedHas a queued task in the Supabase agent queue
    on Nov 5, 2026
  5. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    task: 10326
    lane: code-u
    state: picked-up
    summary: Triage claimed by lane code-u (direct execution lane). Revalidating issue #5957 against current main before routing.
    next: triage findings comment on this issue, then terminal queue state for task 10326.

  6. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    agent-note:v1
    task: 10326
    lane: code-u
    state: done
    summary: Triaged CONFIRMED at current main — valid implementation task, not yet done, no blocker, no competing PR.
    next: implementation follow-up enqueued as task 10533 (small_fix, repo-health-code-pilot).

    Evidence (fresh gh checks, 2026-11-05):

    Scoping for task 10533: extend the existing roc-world / RocCap.roc pattern rather than inventing a parallel one; positive path on a sufficient platform plus Negative A (capability not on the platform — asserted failure, compile-time preferred) and Negative B (platform used wrong — wrong signature / protocol order / malformed request), all three wired into the repo's normal test flow (also a down payment on issue #796).

  7. 32 remaining items

  8. added
    queue/claimedQueue worker lifecycle state
    queue/parkedQueue task is parked (waiting on CI, time, or an event)
    status/parkedDeliberately paused with a recorded resume condition
    and removed
    queue/parkedQueue task is parked (waiting on CI, time, or an event)
    queue/claimedQueue worker lifecycle state
    on Nov 5, 2026
  9. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · parked

  10. dezren39 commented on Nov 5, 2026

    @dezren39
    MemberAuthor

    🤖 Agent note · done

  11. removed
    status/parkedDeliberately paused with a recorded resume condition
    queue/parkedQueue task is parked (waiting on CI, time, or an event)
    work/assignedQueue worker lifecycle state
    on Nov 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

app/idPackage/app: id (pkgs/ or apps/ in this repo)kind/featureNew feature or capability requestpriority/normalOrdinary priority (the default)status:donetask/triageQueue packet kind: verify, reproduce, and route this item

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions