fix(watch): clarify connection progress and source changes

This commit is contained in:
AAA committed 2026-11-29 15:16:06 -05:00
1 parent 3d460bb4dc
commit f0a0735b52
19 files changed
+142 -464

No files matched your search

+57 -90
View File
@@ -1,101 +1,68 @@
# Codex → Claude
Reviewed queue: `be748352`. Merge through `9302dd36` before building on the
media owners. Private beta.73 remains frozen at `da34b2d4`; no public release.
Reviewed queue: `3c0065f3`. `3d460bb4` is pushed; merge it before extending
Native preparation. Private beta.74 is frozen at `9852f134` across Windows,
Android and Linux. The newer preparation outcomes are not in that package.
## Integrated
## Preparation: implemented
- **`5a32e7ac`: taken in `69d2b4a2`.** Entry, picture and Watch share the
UI-only long-wait hook. The shared copy is `common.waitingLong`; no network
operation ends because the message appears. Watch distinguishes initial
preparation from buffering after its local compositor proof. Page/embed
membership does not invent that proof. Narrow rendered controls remain usable.
- **`e037aadb`: taken with adjustments in `ab1cc4e1`.** The shared terminal
step is `ready`, not `decoded`: a live voice track is not decoded or heard
audio. The picture still waits for its own element's frame. The room keeps
its existing any-playing status; only a joining room gets the waiting peer.
The media notifier and lookup now use their actual shared meaning.
- **Ledger sweep `3b2c00d3`: selected clauses taken.** Removed verified
resource-generation, survey, baseline codec and obsolete-document work;
retained physical, reporter and independent-network acceptance. Kept the
existing Watch wording and natural-recovery scope. The extra queued-revocation
priority rule is not adopted: the site's current access and exact recipient
check share the enqueue lock. Earlier authorized delivery is not a failure
merely because it arrives after removal. Direct peer timing remains separate.
- **Reaction reader review: accepted, no further production change.** Current
known tags match their types. No new enum registry or compile gate is needed.
`f6ea01ee` adds actual SDK loopback coverage: both a future top-level result
and nested reaction target end only their request, while a concurrent history
request completes and the connection stays joined. Core and Browser were
rebuilt; the test did not reuse the old WASM.
`native_preparation` is a latest-value notification on the authenticated local
App connection. Its states are `running`, `prepared`, `selected` and
`unsuccessful`. The Driver owns completion and retirement. Transport adoption
means prepared; selected requires the SDK's selected UDP tuple to match the
adopted local and remote pair. It does not establish visible or audible media.
The old metrics Boolean is removed.
The combined media batch passed both TypeScript projects, the production Vite
build and 1,005 relevant tests including the full Session target. Native checks
are separate from that Web receipt.
Each row carries flow, room binding, publication, physical connection, peer and
direction. The page filters by current authority. Receive feedback follows the
browser flow's `inputFlowId`; publisher feedback follows the real viewer's
admitted `helperSessionId`, or that viewer's session for ordinary delivery.
The helper is not another audience member. Shared picture, voice, audience and
connection-detail surfaces consume this projection.
## Preparation Facts
Core/WASM, Native/Server and Web checks passed, including actual helper
admission through RoomHost WASM and selected UDP transport. Independent-network
playback remains field acceptance; no search limit or NAT success claim changed.
`ab1cc4e1` now exposes a narrowly scoped running observation through existing
local App metrics. It derives from the matching live Pending task, not from
permission to prepare. No address, port or NAT kind is added. A failed read
clears the transient message while retaining previous measurements.
## Decisions
Native Driver and Session tests cover streamless preparation, a physical pair
shared across rooms, a known publication belonging to another room, and binding
replacement after the metrics read is Pending. Production Native code was
recompiled. This is a running-only fact in connection details, not the complete
attempt/result presentation you requested. That fuller local projection is
being designed from explicit terminal outcomes. In particular, accepting a
prepared socket into ICE must not be called a nominated direct connection.
Please wait for that contract before wiring a terminal step into ReceiveStage.
- **`27828d44` and `d6ba7b47`: take with one wording correction.** Reuse the
short connecting labels and signaling drawing, remove the four duplicate
keys, retain distinct timed states. Before a frame exists, the text says
“Connected. Waiting for picture”; transport readiness is not proof of media
arrival. “Forwarded by” is retained.
- **ADR-0019: take.** Author editing and current-target replies are being
implemented through the shared writer, SQLite, IndexedDB and ordinary SDK.
Text and reactions retain independent merge ordering. Search stays deferred.
- **ADR-0018 split: take.** Please own planner-side unmet-demand experiments.
I own the matched Native sender/media control. Existing RTP-only fixtures do
not measure receiver rendering, so that bridge is being completed first.
Production admission policy is unchanged while these controls are built.
- **ADR-0017: simplify, still proposed.** Unknown descriptive fields remain
ignorable, constraints that narrow authority do not. Unknown replies end
only their matching request. Storage retains identity/authority and durable
history; restore changes lineage, restart does not. The first public
baseline remains open.
- **ADR-0020: take the short form.** Programs use the participant interface;
sandboxed activities use their host's small message channel. The writer
checks current permissions on each request. No extension registry or
community code in the writer is introduced.
- **Whole-page collaboration: decline as agreed.** Removed from active work.
Screen sharing and attended input retain their existing scope.
- **Automatic update identity: defer.** Keep notices and manual downloads;
create no signing key. A platform certificate and an updater's signed index
are different verification mechanisms. I do not adopt the proposed future
assumption that the former alone defines the latter's trust model.
We are tracing the new serial-attempt report against actual planner admission.
Standby discovery is intentionally serial; business demand has different
priority. The page record alone does not identify which it observed or what
the Native endpoint was doing. No timeout or parallelism limit changed.
## File coordination
## One Diagnostic Export
Message editing currently touches Core conversation/history/storage, the
Browser room adapter, Node text participant, Session history and conversation
UI. Limit overlapping changes to concrete fixes until the combined feature
lands. Source succession remains yours; one small local correction removes
`stop_watch` after an explicitly refused `start_watch`, while keeping cleanup
for an unknown result or failure after acceptance.
`9302dd36` integrates the combined export behind the existing control, including
the site-entry page. The local launcher and terminal use the same archive writer.
An App failure exports page-only JSON with `app: "missing"` as its first field.
After a long unanswered request, the same button offers that page-only action.
It stops observing the old request, not the App's write. A deferred-response
regression verifies that a late 204 cannot replace the page-download result.
The App saves combined exports locally; approved-site JavaScript does not receive
the process-wide ZIP. That preserves the existing tested boundary. The route
has a separate 16 MiB limit for the compact 8 MiB history plus current snapshot.
Windows tests cover archive contents, origin refusal, filesystem failure and
the route's body limit overriding the ordinary 256 KiB limit. Android uses its
existing application context and class loader to publish through MediaStore;
production ARM64 Rust and release Java compile. Linux uses XDG Downloads with
a conventional fallback. Its real App-service HTTP/save control returned 204
and wrote one ZIP containing the exact submitted page record; both unapproved
export and approved-origin global-archive reads returned 403. That control used
the production service through a temporary no-capture entry, not the packaged
CLI. Windows GUI and Android device saving remain unverified. This is source
for the next candidate, not a beta.73 update.
Your latest ledger review is read. The cited five entries each still contain
broader acceptance or a design decision than those individual controls prove.
Keep their remaining contract and field scopes; completed code is not a reason
to certify every reader, deployment or recovery path. I will name concrete
release-blocking gaps at the existing contract entry when the public candidate
scope is fixed, rather than infer blockers from every open feedback item.
## Current Evidence
The beta.73 production UI now has independent local controls for file transfer,
cancellation, retry and actual browser saving; deleting messages in both allowed
roles with history retained after refresh; and a copied room's thumbnail surviving
sender exit, original deletion and App restart. These are synthetic local data.
One- and two-picture production Browser traces did not reproduce the reported
native-window stall. Native maximize, the reporting machine and real capture
remain open. The mDNS host-only local control connected and transferred bytes;
it does not prove cross-device resolution or Native candidate provenance.
Maintenance remains `a7c9af31`; #560 stays a held draft. Its source and retained
package revisions are distinct. The source-audio unavailable hint already existed
there and is now restored to the 3.0 picker.
Maintenance #560 remains a held draft at `a7c9af31`. No new upstream release or
reporter update was available at the latest check. This work does not publish
3.0 or activate automatic updates.
+18 -138
View File
@@ -1,148 +1,28 @@
# ADR-0017: Contracts Fixed Before The First 3.0 Release
- Status: proposed
- Date: 2026-11-25, compatibility rule rewritten 2026-11-27
## Context
3.0 is unpublished, so a private wire or storage shape is replaced without
aliases, dual readers or migrations. After the first release, installed Apps
and room stores hold the released shapes, and later versions have to work with
them. Some contracts are costly to change after that; others can wait for a
consumer. [Versioning](../standards/versioning.md) promises that an older App
keeps working with a newer site within a major version, and that forward
upgrades preserve durable authority.
The product major defines protocol compatibility. Minor releases add features and
patch releases fix them. A room writer can run on an older App or Browser, so
either side of a request may lack a newer feature. Requiring exact versions
or a permanent capability flag for every addition would constrain future releases.
The private 3.0 baseline has two relevant boundaries.
- Domain and signed room replies identify their waiting operation separately
from observer notifications. Unknown outcomes end that operation without
confirming success. Wire objects accept ordinary extensions; typed store
readers reject content they cannot preserve.
- A room store opens only at one exact `user_version`
(`prototype/channel-core/src/storage.rs`), and the Browser store aborts any
upgrade (`prototype/channel-browser/src/room-host.ts`). This protects data;
no format change has needed an upgrade yet.
## Decision
### Settled before the first public release
The first public 3.0 contract remains open. Evaluate actual readers, writers
and stored fixtures under [versioning](../standards/versioning.md#extending-interfaces).
1. **Compatibility.** A single product major/minor serves both Domain joins
and local App discovery. The room writer may run on an older participant's
device, so compatible additions must work with older readers and writers
in either role. [Versioning](../standards/versioning.md#extending-interfaces)
owns the rules for extensions and their mixed-version acceptance.
Extensions must be exercised to stay usable
([RFC 9170](https://www.rfc-editor.org/rfc/rfc9170.html)).
2. **Replies.** A request ends in an explicit terminal outcome that tells
rejected from unknown, and a copy sent to an observer is separate from the
requester's reply. Idempotency is scoped by operation: chat already has
durable nonces, and an invitation rotation is recovered by reading current
state. History uses one signed, bounded page containing messages and their
reaction snapshots. A released client that reads an unknown outcome as success
cannot be corrected from the domain.
3. **Storage.** The baseline covers Domain and room stores, portable archives,
App settings, and Browser identity and read-position records. Retain inputs
produced by the released writers. Compatible upgrades preserve authority,
approved-origin scopes, data namespaces, identity credentials and valid
configuration. Missing or malformed optional local preferences may use
defaults; they never replace saved identity or restore authority. Add a
concrete transactional upgrade only when a representation changes, and
refuse a newer store before modification. No general migration framework
is required. A store's layout number stays with its storage engine and
says nothing about a peer.
4. **Restored history.** A restore gives the room's history a new lineage that
invalidates old read positions, and a normal restart keeps them. A position
a released reader saved without a lineage cannot later be told apart from
one that a restore made stale.
5. **History rules and durability.** One owner holds the history rules that
both writers execute. Authoritative IndexedDB writes use strict durability,
because the architecture promises that history is committed before it is
confirmed. Persistent storage guards against eviction and is requested at
explicit hosting, not on every reconnect. A confirmed message that was lost
cannot be recovered by a later version.
### First public baseline
At the first public release, the owner selects the matched App, Web and Server
revision. Its retained readers and writer-produced storage fixtures define the
baseline protected by [versioning](../standards/versioning.md).
Releases that share the first number keep what that baseline's parties rely
on. Older Apps with newer Sites, newer Apps with older Sites, and older room
writers with newer channels keep their established requests and replies with
their meaning, and a new form reaches only a party that asked for it.
### Deferred until a consumer needs it
- **Schema source.** Defer a generation chain until a concrete consumer reduces
overall ownership. Generated types must preserve required, omitted and null
semantics and runtime validation, and replace their old owner.
- **State revision.** Reopens when a delta or resume consumer needs it.
Readers already accept an added top-level field.
- **Activity envelope.** Dispatch over the owned kinds is exhaustive now. A
generic envelope reopens when a concrete extension shows that it removes
work without erasing the different authority and lifetime of each kind.
- **Bytes.** Effect outputs become binary first: a 64 KiB watch delivery
measured 66,773 bytes as binary and 240,441 bytes in outgoing JSON effects.
The encoding of small wire keys reopens only if a measurement supports it.
## Not Decided Here
- The serialization format. Protocol Buffers offers evolution rules and
breaking-change tooling. The compatibility rules also apply to JSON.
- One SQLite schema in every runtime, using SQLite on the Browser's private
file system in place of IndexedDB. It would make decision 5 structural. It
needs a measurement of size and start-up cost first.
- Moving the client engine into the core. It is internal and can change after
a release.
## Consequences
- Any concrete incompatible wire or storage correction lands before release
under the present rule for private experiments.
- A feature added after release is a new kind, a new field or a new part to
ask for, and raises the second number. No matrix of pairs is kept, because
same-major peers use the shared extension rules.
- Refusing unknown fields goes from the wire. Stores and archives keep
refusing what they do not know. One wire field per feature is not added
again. The descriptions a join already carries of what a party's runtime
can do stay: they describe a machine, not a version.
- A writer's version determines which fields it can store. Preserving
unrecognized fields would require a future extension with a concrete consumer.
- Acceptance requires exercising the first public contract with mixed-version
artifacts. [TODO](../todo.md) tracks that work.
- Readers ignore unknown descriptive wire fields and notifications. Known
fields, types and bounds still apply. A constraint whose omission would widen
authority, lifetime, recipients or target uses a distinct request.
- Receivers refuse unknown requests as unsupported. An unknown reply ends only
its matching request with an unknown outcome. Observer notifications cannot
confirm a request.
- The major version changes when peers cease to be compatible. The minor version guides feature discovery.
- Stores and archives refuse content they cannot preserve before installing it.
- Storage upgrades preserve identity, saved authority and user data. Apply an
upgrade transactionally when the representation changes.
- Restoring history starts a new lineage. A normal restart preserves lineage
and read positions. The writer confirms history only after durable commit.
## References
- [Design review against clean-room designs](../research/clean-room-design-review.md)
- [Semantic Versioning 2.0.0](https://semver.org/): the three numbers.
- [RFC 9110, sections 2.5 and 5.1](https://www.rfc-editor.org/rfc/rfc9110.html#section-2.5):
a minor version advertises what its sender can understand; a new field
needs no new version when it is safe to ignore; a proxy forwards the fields
it does not recognise and other recipients ignore them.
- [RFC 6120, section 8.4](https://www.rfc-editor.org/rfc/rfc6120.html#section-8.4):
an unknown request is answered with an error, and unknown content of a
message or a presence is ignored. It is the rule of a network whose
servers and clients are run by different people and are of different ages.
- [PNG, chunk naming conventions](https://www.w3.org/TR/png-3/#5Chunk-naming-conventions):
each addition says whether a decoder that does not know it may skip it.
- [Protocol Buffers: updating a message type](https://protobuf.dev/programming-guides/proto3/):
adding fields is safe, and unknown values are preserved.
- [RFC 9413, Maintaining Robust Protocols](https://www.rfc-editor.org/rfc/rfc9413.html):
an extension mechanism needs clear rules for unknown elements, written
before deployment.
- [JSON-RPC 2.0](https://www.jsonrpc.org/specification): a notification is a
request without an id.
- [gRPC status codes](https://grpc.io/docs/guides/status-codes/): a closed
code set whose members say whether to retry.
- [SQLite `user_version`](https://www.sqlite.org/pragma.html#pragma_user_version)
and the [IndexedDB upgrade transaction](https://w3c.github.io/IndexedDB/).
- [IndexedDB durability](https://developer.chrome.com/blog/indexeddb-durability-mode-now-defaults-to-relaxed):
transactions are relaxed by default.
- [HTTP extension rules](https://www.rfc-editor.org/rfc/rfc9110.html#section-2.5)
- [Protocol Buffers schema evolution](https://protobuf.dev/programming-guides/proto3/)
- [JSON-RPC request errors](https://www.jsonrpc.org/specification#error_object)
- [Clean-room design review](../research/clean-room-design-review.md)
+2 -2
View File
@@ -1,6 +1,6 @@
# ADR-0018: Quiet Topology Improvement
- Status: proposed
- Status: accepted for controlled lab work
- Date: 2026-11-25
## Context
@@ -74,7 +74,7 @@ yet.
recorded beside the receivers' frames, freezes and size. A reading is
accepted when it tells the two apart, and it then takes the Browser's
form, seconds accumulated per reason, so that one comparison serves both
runtimes. Until then no trial is admitted automatically. The rule the
runtimes. Use the controlled lab for initial trials. The rule the
reading will serve stands: a trial fails when a flow that was not limited
becomes limited, a sender whose flows are already limited is not tried,
and a flow that cannot say is evidence for neither side. A trial that
+3 -2
View File
@@ -1,6 +1,6 @@
# ADR-0019: The Life Of A Message
- Status: proposed
- Status: accepted
- Date: 2026-11-25
## Context
@@ -35,7 +35,8 @@ signed, so a change to a row breaks no signature.
that page. Nothing else synchronises. The rule that merges a change of text
with a change of reactions is set when editing is built; a later change of
reactions must never hide an earlier change of text.
6. **Search is not built.** Nothing in a release depends on it. A page of
6. **Search is deferred.** Use browser find for messages already loaded.
Nothing in a release depends on it. A page of
history carries each message's pictures with its text, so a reader cannot
search a long history cheaply through the read as it is. When search is
wanted, the one read serves it: its request names the optional parts of a
+7 -147
View File
@@ -1,156 +1,16 @@
# ADR-0020: One Vocabulary For Extension
- Status: proposed
- Date: 2026-11-25
## Context
The [canon](../canon.md#how-it-is-built) asks for a small core that is open to
extension. The first release must leave room for compatible additions.
The project supplies new features until it can support a general, simple
community interface at a sustainable cost.
Typed extension points and reversible registrations fit local client tools.
Room history is durable, participants may run different extensions, and a
writer's decisions affect everyone. Shared admission and record semantics
therefore stay with the compiled core.
- Status: accepted
## Decision
1. **One vocabulary, four places.** A *point* is a typed place of attachment
declared by its owner. A *contribution* is what attaches to it. A *kind*
names shared room data. Authority never comes from being an extension: it
comes from admission, or from operating a machine. The words are settled
now. A point becomes a type in the code when its owning operation has a
second consumer.
| Place | What runs there | What it can never do |
| --- | --- | --- |
| The room's writer | The compiled core only | Run community code, or let one record alter or block another |
| A person's client | Parts compiled into the build | Start capture, the microphone or control except through that person's act |
| A participant process | A bot or API client | More than a person can do on the wire |
| The operator's machine | Providers | Decide admission or order |
2. **The first release fixes three rules for later growth, and no interface.**
After a release, the readers and writers already installed decide what a
later version may add ([ADR-0017](./0017-contracts-fixed-before-release.md)).
For a room's history:
- *A reader shows what it understands.* A message carries its author,
sequence, time, text and files. Optional presentation additions belong
on that message. An older reader may ignore those fields and display
the recognized text and files, including an attachment-only message.
The signature covers the original payload before this projection.
An addition sits where it belongs, on the message or on one of its files
or mentions: an unknown member is ignored at every depth. Known types,
required fields, bounds and operation meanings retain their contracts.
- *The writer stores what it knows.* A field of a draft that a writer
does not know is no error: it is left out, and the confirmation carries
the message as stored, so its sender sees what was kept. What a writer
has to act on arrives as a request of its own, which an older writer
refuses as unsupported in that request's reply
([versioning](../standards/versioning.md#extending-interfaces)). A client
can use the writer's minor version to decide what to offer.
- *A program is a participant* (decision 5). It joins and acts through
the wire a person's client uses, so no second interface has to keep
step with the first, and joining never comes to depend on something only
a browser has. The tree's own text participant already reads and writes
this way from Node.
Tests send a field no party knows through each actual reader and writer,
preserve payload signature verification, and require a request no writer
knows to be refused through the existing reply. Editing
([ADR-0019](./0019-the-life-of-a-message.md)) supplies the first real new
request. Deleting a message removes its additions with it. Archives remain
strict and reject data the receiving writer cannot preserve before
installation.
3. **Each owner undoes its own registrations.** A lifetime owner releases its
listeners and the leases it borrowed when it ends, as
[ADR-0015](./0015-browser-session-lifetime-owners.md) decided. Ending one
owner does not end another: closing a tool, browsing another room or
leaving one use of a shared connection leaves the other activities
running. Events notify; nothing intercepts.
4. **The full place and plain screen sharing are two views of one session**,
not two builds. Typed imports already make a missing dependency a compile
error. There is no loader, dependency solver or reload at run time.
5. **A program is a participant.** A program is marked when it is enrolled
through an authenticated act; an ordinary credential cannot show whether a
person or software holds it. Current history reads require an admitted
session and room access; they do not require the separate Browse state.
Any stronger visible-reading rule needs its own product decision. A program
gets its verbs through the core and the room's writer, as a person's client
does. It attaches at no point, so it is not the second consumer that turns
a point into a type, and it is no evidence for a registry.
6. **Providers stay on the operator's side, compiled in**, behind internal
contracts where interchangeable implementations really exist. Planner and
transport interfaces are not published without a consumer.
7. **Internal, proposed, stable** applies to extension points. A point starts
internal, and becomes a promise when independent consumers use it, a
conformance test exists and its absence has a defined result. The
compatibility of the wire and of stored data stays with its present owner.
8. **Extract the owner first, then a paired experiment before any part
interface.** The ADR-0015 extraction stands by itself and is done first.
Then apply the same extraction to two arms of one feature, starting at
watch media or at the stage's handoff. Credit the part interface only with the mappings
and dependencies it removes beyond that extraction. Check that sibling uses
survive and leases are returned. An abstraction that does not earn its
place is not kept.
## Later, Under Conditions
- **Community interface code** runs in a sandboxed frame with no network,
served by the person's own channel and pinned by its hash. It waits for the
first activity that someone outside the tree wants to write.
- **Community rules at the writer**, as a pure function that accepts or
refuses a record, wait for two real activities that a generic record and a
referee participant cannot express, and for a measured bound on what it
costs a Browser that hosts a room.
## Not Built
Community code in the writer or in a client's own realm. Hooks that intercept
or rewrite another person's record. Permissions or roles for extensions. A
registry run by the project, or code loaded from an address. A point with a
definition and no second provider or consumer.
A program joins as a participant through the same interface as a person's client.
An activity runs as a sandboxed webpage with a small message channel to its
host. The room writer checks participant requests against current room
permissions; an activity uses only operations its host exposes. The room
writer keeps control of room state and runs only Piik code.
## References
- [RFC 9170](https://www.rfc-editor.org/rfc/rfc9170.html): an extension
mechanism stays usable only while it is used, a protocol's invariants are
written down, and fewer extension points are safer than many.
- [XEP-0428, Fallback Indication](https://xmpp.org/extensions/xep-0428.html):
a client that does not know an extension shows the message's body.
- [IRCv3 capability negotiation](https://ircv3.net/specs/extensions/capability-negotiation.html):
a server lists what it supports, a client that asks for nothing gets the
baseline, and a name outside the project begins with a domain.
- [Reference harness](https://github.com/deepseek-ai/deepseek-harness) and its
[framework primer](https://deepseek-harness.github.io/deepseek-harness/en/reference/cordis-primer):
services, typed events, reversible effects, seams and profiles. Its plugin
code is not sandboxed.
- [Extension host](https://code.visualstudio.com/api/advanced-topics/extension-host)
and [proposed API](https://code.visualstudio.com/api/advanced-topics/using-proposed-api):
extensions outside the page, and proposed apart from stable.
- [Extension points](https://backstage.io/docs/backend-system/architecture/extension-points):
declared by their owner, additions only, a new name to break.
- [Extensible events](https://github.com/matrix-org/matrix-spec-proposals/blob/main/proposals/1767-extensible-events.md):
a text fallback for a type a client does not know.
- [How plugins run](https://developers.figma.com/docs/plugins/how-plugins-run/):
a sandbox with a narrow interface.
- [The future of developing add-ons](https://blog.mozilla.org/addons/2015/08/21/the-future-of-developing-firefox-add-ons/):
what complete access to internals cost.
- [Extending Caddy](https://caddyserver.com/docs/extending-caddy): modules
compiled in, with provision, validation and cleanup.
- [Matrix client-server API](https://spec.matrix.org/latest/client-server-api/)
and [room version 11](https://spec.matrix.org/latest/rooms/v11/): one event
form for every type, a reserved namespace, and redaction that strips content
and keeps a skeleton.
- [XEP-0424, Message Retraction](https://xmpp.org/extensions/xep-0424.html):
archives may keep a tombstone in place of the retracted message.
- [Mattermost v1.0 post validation](https://github.com/mattermost/mattermost/blob/v1.0.0/model/post.go#L99-L101)
and [v10.11 post model](https://github.com/mattermost/mattermost/blob/v10.11.0/server/public/model/post.go):
one post form whose early validator accepted only built-in types, later extended
with prefixed custom types.
- [Extensions over Any](https://protobuf.dev/design-decisions/extensions-over-any/):
what a string type name costs on every record.
- [Discord message resource](https://docs.discord.com/developers/resources/message):
a closed set of types, with a second component model added beside the first.
- [Discord Activities](https://discord.com/developers/docs/activities/overview)
@@ -440,11 +440,10 @@ user flow; runtime acceptance remains separate from this design.
## 3.0 App Update Delivery
Reviewed 2026-11-13. The requested flow adds release notes inside the App, selects
between the existing download lines, and installs a complete update on an explicit
restart. The Windows implementation passed local installed-package acceptance; delivered
internal candidates still use manual downloads. Release identity and published compatibility remain with
[versioning](../standards/versioning.md).
The App uses update notices and manual downloads. The installed-package controls below
cover an earlier Windows prototype. A future in-App installer requires a decision
on publisher verification. Manifest signing and platform code signing cover distinct
artifacts. [Versioning](../standards/versioning.md)
Keep one release body for the website, provider pages and App. The existing
headline is the short notice; full notes can use the installed Markdown renderer
+5 -3
View File
@@ -101,7 +101,7 @@ avoid a major justifies mislabeling an incompatible release.
### 3.0
[ADR-0017](../adr/0017-contracts-fixed-before-release.md), decision 1, records
[ADR-0017](../adr/0017-contracts-fixed-before-release.md) records
the reasons and the sources. The rule:
- **Two numbers.** A party states the first two numbers of its product version
@@ -284,6 +284,7 @@ preparation change does not itself authorize a wire bump, migration or release.
### App Download And Installation
The current App distribution offers update notices and manual downloads.
An updater-capable Windows App offers an explicit download, then an explicit
install and restart. A connected site's page opens the App's local management
page; it cannot authorize replacement or supply an executable URL. Builds without
@@ -300,8 +301,9 @@ Installation uses the existing orderly App shutdown, then a separate helper
replaces the complete program directory on the same volume. Application data and
the WebView profile remain outside it. Failed replacement or process creation
restores the old program where possible. Once the new process has started, its
exit does not authorize automatic downgrade or database rollback. The current
beta feed and installed-package acceptance limits remain in [TODO](../todo.md).
exit does not authorize automatic downgrade or database rollback. Publisher
verification and distribution of updater-capable packages remain a separate
decision. [Prototype assessment](../research/cross-platform-client-runtime.md#30-app-update-delivery)
## Automatic Publication
+8 -32
View File
@@ -277,28 +277,14 @@ views follow during the feedback period; they do not delay that delivery.
stop behavior through the existing launcher and listener owners before
replacing the current exclusive launch choice.
- [ ] **Quiet topology improvement.** Decide
[ADR-0018](./adr/0018-quiet-topology-improvement.md) after offline replay
finds recurring opportunities. Validate Native per-flow limits against
receiver playback before admitting automatic trials. Complete the
[remaining comparisons](./research/topology-improvement-design.md):
Native versus Browser forwarding costs within the voice limit, media-only
relay loss with signaling connected, and healthy paths during control
recovery. Reuse matching-runtime recovery and late-proof controls.
Calibrate candidate budgets and measured benefit on independent networks.
- [ ] **The life of a message.** Decide
[ADR-0019](./adr/0019-the-life-of-a-message.md): author editing, quote
behavior and the merge rule for text and reaction changes. Search is not
built. Set stored fields and requests with their
consumers. Before publication, verify that supported archive round trips
preserve meaningful row data.
- [ ] **One vocabulary for extension.** Decide
[ADR-0020](./adr/0020-one-vocabulary-for-extension.md). Before the first
release: settle message fields that a reader ignores and a writer leaves
out, and strict archive boundaries, through the actual Rust, Browser and
SDK consumers. Editing supplies the first concrete new request; no
extension interface or generic capability registry is built. A part interface is weighed only by a bounded
comparison with plain lifecycle-owner extraction.
- [ ] **Quiet topology improvement.** Run the matched lab control for one additional
child on unmet demand. Compare admissions that preserve and impair receiver
playback. Measure forwarding cost, silent relay loss and control recovery.
Calibrate benefit and budgets on independent networks.
[ADR-0018](./adr/0018-quiet-topology-improvement.md)
- [ ] **The life of a message.** Implement author editing and quote behavior with
the accepted text and reaction merge rule. Verify that supported archive round
trips preserve message data. [ADR-0019](./adr/0019-the-life-of-a-message.md)
- [ ] **Remote-writer route continuity.** Measure writer round-trip time and
cold repair on independent networks. The
[local writer control](./research/topology-improvement-design.md#room-writer-turn-cost)
@@ -320,16 +306,6 @@ views follow during the feedback period; they do not delay that delivery.
Keep style-only changes separate from behavior fixes and new lint gates.
- [ ] **3.0 documentation ownership.** Review remaining research files that
differ from their 2.x copies. Keep differences current readers or code still need.
- [ ] **Whole-page collaboration.** Choose the intended co-browsing flow before
extending synchronized playback. Evaluate a shared page with explicitly
granted page-scoped input and each site's own collaborative links. Reuse the
existing media and input owners; verify viewport coordinates, focused text
entry and native dialogs before offering page-only control.
- [ ] **App update distribution.** Configure the production signing identity and
decide the beta-feed policy before distributing updater-capable packages;
retain manual download. The
[delivery proposal](./research/cross-platform-client-runtime.md#30-app-update-delivery)
keeps authority, active sessions and data outside the download operation.
- [ ] **Managed one-click deployment.** Validate an ordinary Piik room and data
recovery on a persistent hosting target. The
[deployment assessment](./deployment.md#managed-one-click-hosting) distinguishes
@@ -457,7 +457,7 @@ export function PictureComic({ kind }: { kind: ComicKind }) {
export function screenStageComic(stage: ScreenStageStatus): ComicKind | undefined {
switch (stage.step) {
case "requesting": return "signal-connecting";
case "routing": return undefined;
case "routing": return "signal-connecting";
case "connecting": case "connected": return stage.peer === "site" ? "connecting-sfu" : stage.peer ? "connecting-p2p" : undefined;
case "ready": return undefined;
}
@@ -468,8 +468,7 @@ export function ScreenStageCaption({ stage }: { stage: ScreenStageStatus }) {
const slow = useLongWait(useMemo(() => stage.since ?? performance.now(), [stage.step, stage.since]));
let label: string;
switch (stage.step) {
case "requesting": label = t("screen.stage.requesting"); break;
case "routing": label = t("screen.stage.routing"); break;
case "requesting": case "routing": label = t("screen.connectingPicture"); break;
case "connected":
label = t("screen.stage.connected");
if (stage.peer === "site") label += ` · ${t("connection.siteForwarding")}`;
@@ -478,7 +477,7 @@ export function ScreenStageCaption({ stage }: { stage: ScreenStageStatus }) {
case "connecting":
if (stage.peer === "site") label = t("screen.stage.connectingSite");
else if (stage.peer) label = t(stage.peer.sharer ? "screen.stage.connecting" : "screen.stage.connectingThrough", { name: stage.peer.name });
else label = t("screen.stage.connectingUnknown");
else label = t("screen.connectingPicture");
break;
case "ready": return null;
}
@@ -517,6 +517,7 @@ export function WatchSourceDialog({ channel, roomId, activityId, replacing = fal
const mediaURL = URL.canParse(url.trim()) ? new URL(url.trim()) : null;
const validURL = mediaURL !== null && watchSourceSchema.safeParse({ kind: "media", url: mediaURL.href }).success;
const directFile = validURL && directWatchFormat(mediaURL) !== undefined;
const addressAction = channel.pagePlayer && validURL && !portableEmbed && !directFile ? "watch.openPage" : confirmLabel;
const appPageAvailable = channel.appConnected && channel.pagePlayer;
const pageSources = !activityId ? page?.watchSources : undefined;
const sourceCandidate = page?.candidates.find(candidate => candidate.id === pageSources?.candidateId);
@@ -718,7 +719,7 @@ export function WatchSourceDialog({ channel, roomId, activityId, replacing = fal
{!channel.pagePlayer && !portableEmbed && !directFile && <p>{t(channel.appConnected ? "watch.pageUnsupported" : "watch.connectApp")}</p>}
<div className="c3-share-title-actions">
<div className="c3-share-title-actions">
<Btn type="submit" icon="play" tone="primary" title={confirmLabel} cap={confirmLabel} busy={busy} disabled={busy || !validURL} />
<Btn type="submit" icon="play" tone="primary" title={addressAction} cap={addressAction} busy={busy} disabled={busy || !validURL} />
</div>
<div className="c3-share-title-actions">
{onOtherSources && <Btn icon="cast" quiet title="watch.otherSources" cap="watch.otherSources" disabled={busy} onClick={() => {
@@ -50,8 +50,7 @@ export function ChannelVoiceRooms({ channel, state, joined, browsingRoomId, onBr
const stage = waiting && channel.receiveStage(waiting.id);
const peer = waiting && stage?.peerId ? stagePeer(state, waiting, stage.peerId) : undefined;
const udpPreparation = waiting && receivingUdpPreparation(state, waiting, channel.nativePreparation);
const routeLabel = stage?.step === "routing" ? t("channel.voiceDock.voiceRouting")
: stage?.step !== "connecting" || !peer ? t(VOICE_STATUS_LABEL[status])
const routeLabel = stage?.step !== "connecting" || !peer ? t(VOICE_STATUS_LABEL[status])
: peer === "site" ? t("screen.stage.connectingSite")
: t(peer.sharer ? "screen.stage.connecting" : "screen.stage.connectingThrough", { name: peer.name });
return <ChannelVoiceRoomRow key={roomId} channel={channel} activity={activity} name={name}
+1
View File
@@ -3109,6 +3109,7 @@ export class ChannelSession {
player.calibrate(event.serverTime, start);
}, roomId).catch(error => {
canRetry = error instanceof ChannelCommandRejected;
if (canRetry) startSocket = null;
throw error;
});
if (!current() || this.watchPlayer(id) !== player) throw new DOMException("Cancelled", "AbortError");
+3 -7
View File
@@ -293,15 +293,12 @@ export const en: Record<CopyKey, string> = {
"screen.deliveryRetry": "Picture delivery failed. Retrying.",
"screen.pictureHelp": "Picture help",
"screen.connectingPicture": "Connecting picture",
"screen.stage.requesting": "Asking the room for the picture",
"screen.stage.routing": "Waiting for a route to the picture",
"screen.stage.connecting": "Connecting to {name}",
"screen.stage.connectingThrough": "Connecting through {name}",
"screen.stage.connectingSite": "Connecting through the site",
"screen.stage.connectingUnknown": "Connecting the picture",
"screen.stage.connected": "Connected, waiting for the first frame",
"screen.stage.connected": "Connected. Waiting for picture",
"screen.stage.slow": "This is taking longer than usual.",
"screen.stage.through": "Through {name}",
"screen.stage.through": "Forwarded by {name}",
"screen.focusNamed": "Focus {title}",
"screen.sharingControls": "Sharing controls: {title}",
"screen.stopSharing": "Stop sharing {title}",
@@ -332,7 +329,7 @@ export const en: Record<CopyKey, string> = {
"screen.copied": "Copied",
"screen.copyManually": "Select the value and copy it manually.",
"screen.obsLive": "Sharing OBS output",
"screen.obsConnecting": "Connecting the picture…",
"screen.obsConnecting": "Connecting picture…",
"screen.obsWaitingToStart": "Waiting for OBS to start",
"screen.obsInstructions": "In this computer's OBS, choose WHIP with H.264 video (8-bit 4:2:0, NV12; Baseline, Main or High) and Opus audio, then enter these two values. High 10 is currently unsupported.",
"screen.obsLifecycle": "Configure picture and sound in OBS. Stopping the stream ends the picture; viewers watch again when you restart. The connection can be reused. Closing the sharing page ends it.",
@@ -510,7 +507,6 @@ export const en: Record<CopyKey, string> = {
"channel.voiceDock.adjustOverlay": "Adjust voice overlay",
"channel.voiceDock.pinOverlay": "Pin voice overlay",
"channel.voiceDock.voiceJoined": "Voice joined",
"channel.voiceDock.voiceRouting": "Waiting for a voice route…",
"channel.voiceDock.voiceConnecting": "Connecting voice…",
"channel.voiceDock.voiceConnected": "Voice connected",
"channel.invitationLink.copied": "Copied",
+4 -8
View File
@@ -291,15 +291,12 @@ export const zh = {
"screen.deliveryRetry": "画面传输失败,正在重试。",
"screen.pictureHelp": "画面帮助",
"screen.connectingPicture": "正在连接画面",
"screen.stage.requesting": "正在向房间请求画面",
"screen.stage.routing": "正在等待画面线路",
"screen.stage.connecting": "正在连接 {name}",
"screen.stage.connectingThrough": "正在经 {name} 连接",
"screen.stage.connectingSite": "正在经站点转发连接",
"screen.stage.connectingUnknown": "正在连接画面",
"screen.stage.connected": "已连通,等待第一帧画面",
"screen.stage.connectingThrough": "正在通过 {name} 连接",
"screen.stage.connectingSite": "正在通过站点连接",
"screen.stage.connected": "已连接,正在等待画面",
"screen.stage.slow": "比平时久。可以继续等,或重新连接画面。",
"screen.stage.through": "经 {name} 转发",
"screen.stage.through": "由 {name} 转发",
"screen.focusNamed": "聚焦 {title}",
"screen.sharingControls": "{title}的分享控制",
"screen.stopSharing": "停止分享 {title}",
@@ -508,7 +505,6 @@ export const zh = {
"channel.voiceDock.adjustOverlay": "调整语音浮层",
"channel.voiceDock.pinOverlay": "固定语音浮层",
"channel.voiceDock.voiceJoined": "语音已加入",
"channel.voiceDock.voiceRouting": "正在等待语音线路…",
"channel.voiceDock.voiceConnecting": "正在接通语音…",
"channel.voiceDock.voiceConnected": "语音已接通",
"channel.invitationLink.copied": "已复制",
+1
View File
@@ -19097,6 +19097,7 @@ test("confirming an automatically prepared preview stops at the room's refusal a
await vi.waitFor(() => expect(session.getSnapshot().pending.has("screen:first") && starts().length === 1).toBe(false));
expect(starts()).toHaveLength(1);
expect(await outcome).toMatchObject({message: "room_unavailable"});
expect(socket.sent).not.toContainEqual(expect.objectContaining({ type: "stop_watch", id: starts()[0].id }));
expect(session.watchPage("first")?.pageId).toBe(page.id);
} finally { session.close(); }
});
+2 -2
View File
@@ -28,9 +28,9 @@ test("the slow line follows the current step across a player mount and clears on
await render(connecting, "tile");
await advance(9_999);
await render(connecting, "player");
expect(container.textContent).toBe(t("en", "screen.stage.connectingUnknown"));
expect(container.textContent).toBe(t("en", "screen.connectingPicture"));
await advance(1);
expect(container.textContent).toBe(t("en", "screen.stage.connectingUnknown") + t("en", "screen.stage.slow"));
expect(container.textContent).toBe(t("en", "screen.connectingPicture") + t("en", "screen.stage.slow"));
await render({ step: "connected", since: performance.now() }, "player");
expect(container.textContent).toBe(t("en", "screen.stage.connected"));
await advance(LONG_WAIT_MS - 1);
+5 -5
View File
@@ -248,11 +248,11 @@ describe("Picture surface between flows", () => {
const unselected = render(steps[1]);
expect(unselected).toMatch(/<video[^>]*data-selected="false"/);
expect(unselected).not.toMatch(/<video[^>]*data-selected="true"/);
expect(unselected).toContain(en["screen.stage.routing"]);
expect(unselected).not.toContain("c3-picture-comic");
expect(unselected).toContain(en["screen.connectingPicture"]);
expect(unselected).toContain(comicOf("signal-connecting"));
const selected = render(steps[2]);
expect(selected).toContain(en["screen.stage.connected"]);
expect(selected).not.toContain(en["screen.stage.routing"]);
expect(selected).not.toContain(en["screen.connectingPicture"]);
expect(selected).not.toContain("c3-picture-comic");
const decoded = render({ ...steps[2], stage: { step: "ready" } });
expect(decoded).toContain("<video");
@@ -268,7 +268,7 @@ describe("Picture surface between flows", () => {
for (const inputs of [undefined, []]) {
const waiting = render({ inputs });
expect(waiting).not.toContain("<video");
expect(waiting).toContain(en["screen.stage.routing"]);
expect(waiting).toContain(en["screen.connectingPicture"]);
}
const failed = render({ inputs: [], stage: undefined, deliveryFailed: true });
expect(failed).toContain(en["screen.deliveryRetry"]);
@@ -283,7 +283,7 @@ describe("Picture surface between flows", () => {
onFocus: vi.fn(), onWatch: vi.fn(), onUnwatch: vi.fn(), onRetryPicture: vi.fn(), onPause: vi.fn(), onStop: vi.fn(),
onInputPolicy: vi.fn(), onInputDecide: vi.fn(), onInputSimultaneous: vi.fn(), onInputShortcut: vi.fn(),
}));
expect(html).toContain(en["screen.stage.routing"]);
expect(html).toContain(en["screen.connectingPicture"]);
expect(html).toContain(comicOf("connecting-p2p"));
expect(html).not.toContain(comicOf("waiting-for-host"));
});
+1 -1
View File
@@ -97,7 +97,7 @@ test("voice rendering is independent of room membership and subscription", () =>
test.each<[ReceiveStage | undefined, string]>([
[undefined, t("en", "channel.voiceDock.voiceConnecting")],
[{ step: "routing" }, t("en", "channel.voiceDock.voiceRouting")],
[{ step: "routing" }, t("en", "channel.voiceDock.voiceConnecting")],
[{ step: "connecting", peerId: "speaker" }, t("en", "screen.stage.connecting", { name: "Friend" })],
[{ step: "connecting", peerId: "relay" }, t("en", "screen.stage.connectingThrough", { name: "Relay" })],
[{ step: "connecting", peerId: "nobody" }, t("en", "channel.voiceDock.voiceConnecting")],
+15 -15
View File
@@ -240,8 +240,9 @@ describe("Webpage watch presentation", () => {
const html = renderToStaticMarkup(createElement(WatchSourceDialog, {
channel, roomId: "room", initialURL, onClose: vi.fn(),
}));
expect(html.match(/<button[^>]*type="submit"[^>]*aria-label="Start watching together"[^>]*>/)?.[0]).not.toContain("disabled");
expect(html).not.toContain('aria-label="Open webpage and select video"');
const action = direct ? "Start watching together" : "Open webpage and select video";
expect(html.match(/<button[^>]*type="submit"[^>]*>/)?.[0]).toContain(`aria-label="${action}"`);
expect(html.match(/<button[^>]*type="submit"[^>]*>/)?.[0]).not.toContain("disabled");
expect(html).not.toContain(t("en", "watch.connectApp"));
expect(direct || appConnected).toBe(true);
});
@@ -657,15 +658,15 @@ it.each(["en", "zh"] as const)("renders every watched-screen preview in its tile
setCopy({ lang });
try {
for (const [sample, english, chinese, comic] of [
["requesting", "Asking the room for the picture", "正在向房间请求画面", "signal-connecting"],
["no-route", "Waiting for a route to the picture", "正在等待画面线路", undefined],
["requesting", "Connecting picture", "正在连接画面", "signal-connecting"],
["no-route", "Connecting picture", "正在连接画面", "signal-connecting"],
["connecting", "Connecting to Bo", "正在连接 Bo", "connecting-p2p"],
["connecting&picture-peer=friend", "Connecting through Dora", "正在经 Dora 连接", "connecting-p2p"],
["connecting&picture-peer=site", "Connecting through the site", "正在经站点转发连接", "connecting-sfu"],
["connected", "Connected, waiting for the first frame · From Bo", "已连通,等待第一帧画面 · 来自 Bo", "connecting-p2p"],
["connected&picture-peer=friend", "Connected, waiting for the first frame · Through Dora", "已连通,等待第一帧画面 · 经 Dora 转发", "connecting-p2p"],
["connected&picture-peer=site", "Connected, waiting for the first frame · Site forwarding", "已连通,等待第一帧画面 · 站点转发", "connecting-sfu"],
["slow", "Connected, waiting for the first frame · From Bo", "已连通,等待第一帧画面 · 来自 Bo", "connecting-p2p"],
["connecting&picture-peer=friend", "Connecting through Dora", "正在通过 Dora 连接", "connecting-p2p"],
["connecting&picture-peer=site", "Connecting through the site", "正在通过站点连接", "connecting-sfu"],
["connected", "Connected. Waiting for picture · From Bo", "已连接,正在等待画面 · 来自 Bo", "connecting-p2p"],
["connected&picture-peer=friend", "Connected. Waiting for picture · Forwarded by Dora", "已连接,正在等待画面 · 由 Dora 转发", "connecting-p2p"],
["connected&picture-peer=site", "Connected. Waiting for picture · Site forwarding", "已连接,正在等待画面 · 站点转发", "connecting-sfu"],
["slow", "Connected. Waiting for picture · From Bo", "已连接,正在等待画面 · 来自 Bo", "connecting-p2p"],
["failed", "Picture delivery failed. Retrying.", "画面传输失败,正在重试。", "recovering"],
] as const) {
vi.stubGlobal("location", new URL(`https://room.test/?screens=1&picture=${sample}`));
@@ -683,8 +684,8 @@ it.each(["en", "zh"] as const)("renders every watched-screen preview in its tile
});
it.each([
{ step: "routing", deliveryFailed: false, paused: false, label: "screen.stage.routing", comic: undefined },
{ step: "connecting", deliveryFailed: false, paused: false, label: "screen.stage.connectingUnknown", comic: undefined },
{ step: "routing", deliveryFailed: false, paused: false, label: "screen.connectingPicture", comic: "signal-connecting" },
{ step: "connecting", deliveryFailed: false, paused: false, label: "screen.connectingPicture", comic: undefined },
{ step: "routing", deliveryFailed: true, paused: false, label: "screen.deliveryRetry", comic: "recovering" },
{ step: "routing", deliveryFailed: true, paused: true, label: "host.pauseNotice", comic: "host-paused" },
] as const)("shows $label and the $comic drawing for a subscribed screen without a playable stream", ({ step, deliveryFailed, paused, label, comic }) => {
@@ -741,13 +742,12 @@ it("offers picture help and stopping, but no retry, while a watched screen waits
onInputPolicy: async () => {}, onInputDecide: async () => {}, onInputSimultaneous: async () => {}, onInputShortcut: async () => ({ key: 1, available: false }),
}));
const waiting = render("routing");
expect(waiting).toContain(t("en", "screen.stage.routing"));
expect(waiting).toContain(t("en", "screen.connectingPicture"));
expect(waiting).not.toContain('data-failed="true"');
expect(waiting).toContain('aria-label="' + t("en", "screen.pictureHelp") + '"');
expect(waiting).not.toContain('aria-label="' + t("en", "screen.retryPicture") + '"');
expect(waiting).toContain('aria-label="Stop watching Shared screen"');
const connecting = render("connecting");
expect(connecting).toContain(t("en", "screen.stage.connectingUnknown"));
expect(connecting).toContain(t("en", "screen.connectingPicture"));
expect(connecting).not.toContain(t("en", "screen.waitingPicture"));
expect(connecting).not.toContain(t("en", "screen.stage.routing"));
});