GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — feat(id): audio/1 WorldSurface kind — host validation, text projection, contract revision 14 (#12657 slice 1b) by dezren39 · Pull Request #12843 · developing-today/code

Conversation

@dezren39

@dezren39 dezren39 commented Nov 23, 2026 •
edited by blacksmith-sh Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Slice 1b of #12657 (rich-presentation contract; design doc/2026-11-01_design_id788.md step 3): the audio WorldSurface kind — contract only. No renderer/player (slice 2b), no widget kind (slice 1c).

Payload decision (the question the triage left to this slice)

Descriptive cues only — no embedded bytes. An audio/1 document is a bounded list of cues; each cue names a sound (id, label) and describes it: a format from the closed set (wav, ogg, mp3), a duration_ms, and a repeat flag. There are no byte, URL, script or gain fields: a presenter resolves each cue id against the world's own assets and derives everything audible from the description. Rationale: surfaces are centrally validated presentation documents under a serialized-size cap and the frame budget; embedding media would blow both, duplicate the world's own asset path, and force every presenter to carry a decoder for guest bytes. This matches the scene kind's precedent (data only; renderers derive the rest).

What lands

  • AudioSurface / AudioCue / AudioFormat in id-core world_presentation, following the scene/form per-kind pattern: own payload struct, version == 1, deny_unknown_fields, host validation central in parse_surface.
  • Bounds: MAX_AUDIO_CUES 64, MAX_AUDIO_BYTES 64 KiB (serialized), MAX_AUDIO_DURATION_MS 3,600,000 (one hour per cue). Cue ids unique + safe-id, labels/title safe-text, durations in 1..=max. All-integer fields keep the derived Eq WorldSurface relies on — no float bit-exactness caveat.
  • text_projection() — the deliberately exhaustive fallback: the title (or Audio), then one numbered line per cue, N. <label> (<format>; <duration> ms[; repeats]). Pinned byte-exact by test.
  • parse_surface dispatches kind: "audio"; the id(world_presentation): parse_surface collapses duplicate JSON keys before its checks — a forbidden version, width, lines, or rows hidden behind a duplicate is accepted #6491/Design: a duplicate key is a parse error — one duplicate-key refusal contract for pkgs/id's checked JSON gates #6520 duplicate-key guard now names audio alongside screen/text/form/scene. Unknown kinds still drop to the legacy path (the conformance case now uses widget + a fictional kind).
  • Contract revision 13 → 14; the surface feature note documents audio/1. id-cli render_view_frame maps Audio to None like Form/Scene, and the contract-check transcript gains an audio view frame (pin v1.14); id-worlds shell-contract tests pin revision 14. The native shell needs no change: its wildcard arm already presents the text projection.

Verification

  • Failing-first (tests-only commit a1f09f446, fleet-run 45101105846): world_presentation suite 45 passed, 2 failed — exactly the two new audio tests (audio documents dropped to the legacy path on main).
  • With the implementation (fleet-run 45105557422, cargo test -p id-core -p id-worlds -p id-cli --no-fail-fast in the pkgs/id dev shell): 2,621 passed, 1 failed across 34 targets. Both audio tests pass.
  • The one failure is pre-existing on main and unrelated: cli::tests::test_command_lists_cover_all_clap_subcommands — "README CLI Commands table omits walk". The walk subcommand landed after slice 1a's green run via the id: walking skeleton for #9106 — a signed record at an id:// address synced between two nodes #12232 B3 commits (5bb1ab3bc, d09de3199) without the table row; this PR's diff touches no CLI or README files. Recorded on id: walking skeleton for #9106 — a signed record at an id:// address synced between two nodes #12232 (comment 7090694166).
  • Not run as a gate: cargo fmt --check in the fleet image — its rustfmt reformats main's own committed scene code too (8 diffs, 5 in files/lines this PR does not touch), i.e. pre-existing toolchain style drift; the new code mirrors main's committed formatting exactly, as slice 1a did.

Refs #12657 (slice 1b of its step 1; the issue stays open for 1c and step 2).


Proof this PR
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
archer added 2 commits November 23, 2026 02:26
archer
test(id-core): audio surface conformance cases (#12657 slice 1b)
a1f09f4
Tests only: a versioned audio document parses, projects to text
byte-exactly and round-trips; malformed, oversized, bad-version,
unknown-field/format, duplicate-id and out-of-bound documents are
refused by parse_surface. All fail on main, where kind audio still
drops to the legacy path.
archer
feat(id): audio/1 WorldSurface kind — host validation, text projectio…
28f7d57
…n, contract revision 14 (#12657 slice 1b)

AudioSurface/AudioCue/AudioFormat in id-core world_presentation,
following the scene kind's per-kind pattern: own payload struct,
version == 1, deny_unknown_fields, host validation central in
parse_surface. Payload decision (the question the #12657 triage left
to this slice): descriptive cues only — a cue names a sound and
describes it (closed format set wav/ogg/mp3, duration_ms, repeat);
no embedded bytes, URLs or scripts, so presenters resolve cue ids
against the world's own assets and the document stays a bounded
presentation like scene/1.

Bounds: MAX_AUDIO_CUES 64, MAX_AUDIO_BYTES 64 KiB (serialized),
MAX_AUDIO_DURATION_MS 3_600_000 (one hour per cue). Cue ids unique +
safe-id, labels/title safe-text. All-integer fields keep the derived
Eq that WorldSurface relies on — no float bit-exactness caveat.

text_projection(): the title (or Audio), then one numbered line per
cue, 'N. <label> (<format>; <duration> ms[; repeats])'. Pinned
byte-exact by test.

parse_surface dispatches kind audio; the #6491/#6520 duplicate-key
guard now names audio alongside screen/text/form/scene. The
unknown-kind conformance case moves to widget + a fictional kind.

Contract revision 13 -> 14 (surface feature note documents audio/1);
id-cli render_view_frame maps Audio to None like Form/Scene, and the
contract-check transcript gains an audio view frame (pin v1.14);
id-worlds shell-contract tests pin revision 14.
@dezren39
dezren39 requested a review from a team as a code owner November 23, 2026 03:42
@coderabbitai

coderabbitai Bot commented Nov 23, 2026

Copy link
Copy Markdown

Warning

Review limit reached

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Next included review available in 47 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

Learn how review limits work.

Review configuration:

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: dc0ce9dc-23ef-48e8-87a1-486623556cfb
Commits

Reviewing files that changed from the base of the PR and between ff6c05b and 28f7d57.

Files selected for processing: 4

  • pkgs/id/contract/shell-contract.v1.json
  • pkgs/id/crates/id-cli/src/commands/world.rs
  • pkgs/id/crates/id-core/src/world_presentation.rs
  • pkgs/id/crates/id-worlds/src/shell_contract/tests.rs
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

  • X
  • Mastodon
  • Reddit
  • LinkedIn
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@dezren39
dezren39 merged commit f06c0ee into main Nov 23, 2026
2 checks passed

Uh oh!

There was an error while loading. Please reload this page.

@dezren39
dezren39 deleted the archer-lane-bo/12657-audio branch November 23, 2026 03:42
This was referenced Nov 23, 2026
id: rich presentation surfaces — versioned scene/audio/widget contract extension + Bevy renderers (F13.6 follow-on) #12657
Closed
AUDIT-7 Lane 4 — MERGED-PR-AUDIT: merged PRs since 2026-10-23 vs their spawning issues #13879
Open
@developing-today-fleet developing-today-fleet Bot mentioned this pull request Nov 27, 2026
Audit programme: seven-lane review of PRs, issues and designs (2026-11-23) #13871
Open
@developing-today-fleet developing-today-fleet Bot added the audit:completed-later Gap completed by later merged PR label Nov 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

No reviews

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

audit:completed-later Gap completed by later merged PR

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

1 participant

@dezren39
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.