diff --git a/AGENTS.md b/AGENTS.md index bdcf453a..024ad70e 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -76,7 +76,7 @@ says who runs each one and when. form, and no API key or token in the bundle or in the app's storage. The gate refuses only password and one-time-code fields; a key kept anywhere else is still a secret the app holds. Accounts go through a host service's - sheet ([docs/HOST-SERVICES.md](docs/HOST-SERVICES.md)). Use the [compatible RC2 release](README.md#compatible-shell-download), + sheet ([docs/HOST-SERVICES.md](docs/HOST-SERVICES.md)). Use the [compatible release](README.md#compatible-shell-download), within its platform limits, to sign the person in to the app's own backend: the bundle declares it in a signed `backend` block, or the host's operator registers it @@ -141,14 +141,24 @@ says who runs each one and when. imports additionally require `host-api-v1` and `host_api.required: {"wasm.sockets": 1}`. [Published desktop RC6](README.md#compatible-shell-download) provides this API; RC5 does not provide sockets. Missing disclosures - must not become execution gates. OctoSense #453 merged component, - HTTP and host-service integration; App Hub #186/#188 are also merged. - Compatible release and actual app acceptance remain separate. + must not become execution gates. OctoSense #436, #451, #452, #454 and + #455 merged component loading, HTTP, host-service imports and shared + components; App Hub #186/#188 are also merged. Desktop RC5 is the first + release where a component's HTTPS works (RC4 panicked choosing a TLS + provider, OctoSense #471) and the first with `charts.d3@1`. + [Repo Radar](https://github.com/ymote/octosense-repo-radar) is the public-catalog proof of the component + path: HTTPS to GitHub through the SDK, native charts, and the app's + state owned by the component. Compatible release and actual app + acceptance remain separate. Preserve app/account scope, quotas, consent and native reviews. - `card-host` answers every call with - `no service answers "wasm" on this device`. An isolated Wasm fixture is - not evidence that your app's functions work; test its exact bundle and - host. + `no service answers "wasm" on this device`, and refuses an app that + requires `host-api-v1`. An app that requires `wasm-components-v1` or + `host-api-v1` is therefore driven in the compatible release with the + shell's Makepad instrument, in a profile of its own, as Repo Radar's + [native acceptance](https://github.com/ymote/octosense-repo-radar/blob/main/tools/NATIVE-ACCEPTANCE.md) does; never remove a `requires` entry + to make a preview pass. An isolated Wasm fixture is not evidence that + your app's functions work; test its exact bundle and host. - **Only needed capabilities.** Map each capability to something a screen does ([docs/CAPABILITIES.md](docs/CAPABILITIES.md)), and remove the rest. - **Check that a family serves store apps before you build on it.** The gate @@ -284,7 +294,7 @@ Hand off only when all of these hold: `listing.json` and inspected. 3. You have driven every interaction in the brief natively in `card-host` (click, type and tap through the remote bridge) and observed its effect. - For an app that `card-host` refuses, use the compatible RC2 release ([docs/HOST-API-V1.md](docs/HOST-API-V1.md#before-publishing)). + For an app that `card-host` refuses, use the [compatible release](README.md#compatible-shell-download) ([docs/HOST-API-V1.md](docs/HOST-API-V1.md#before-publishing)); for one with its own component, see [docs/RUST.md](docs/RUST.md#6-test-it). 4. You have exercised the empty, error and restart states. 5. The `hub scan` packet is written outside the bundle and its questions are answered: seven, or eight when the bundle ships `tools.json`, `AGENT.md` diff --git a/docs/RUST.md b/docs/RUST.md index d0eda9dd..2aa63253 100644 --- a/docs/RUST.md +++ b/docs/RUST.md @@ -25,6 +25,24 @@ RC5 does not provide it. Test each app on its claimed platforms. See [TCP, UDP and DNS](#tcp-udp-and-dns). No native library or privileged raw-IP socket access is added. +**RC5: component HTTPS and charts.** [Desktop RC5](https://github.com/OctoSense-org/OctoSense/releases/tag/desktop-v0.1.0-rc.5) is published at +source `83d356c2` (11 October 2026). It is the first release where a +component's HTTPS request works: RC4 panicked while choosing a TLS provider +on the first `wasi:http` request ([#471](https://github.com/OctoSense-org/OctoSense/pull/471)). It also registers the +native D3 charts an app can require with `charts.d3@1` +([#470](https://github.com/OctoSense-org/OctoSense/pull/470)). [Repo Radar](https://github.com/ymote/octosense-repo-radar) is the first component app +installed from the official public catalog: on the public RC5 Mac package, +its [public-store acceptance](https://github.com/ymote/octosense-repo-radar/blob/main/review/acceptance-public-store-0.1.2.json) passed 93 native checks that +covered live GitHub requests through `octosense_component::http`, native +charts, and a watchlist the component keeps in its own storage across a +restart. Its sealed component is ordinary Rust over `serde`, `serde_json`, +`semver`, `time` and the SDK, 496 KB when built for size; each call makes at most +one request, with a 3 s request timeout under the 10 s call deadline, and +parses at most 2 MiB of response, since the SDK buffers the body. It +requires `wasm-components-v1` and `host-api-v1` with +`host_api.required: {"charts.d3": 1}`, so RC4 refuses to install it. RC6 keeps all of this and adds sockets +(above). + **Historical RC4 baseline, unchanged.** [Desktop RC4](https://github.com/OctoSense-org/OctoSense/releases/tag/desktop-v0.1.0-rc.4) is published at source `9266b008`, with component loading, HTTP, public host-service imports and shared catalog components. Its App Hub contract 1.11 @@ -48,7 +66,7 @@ retain their original scope. | App Hub's gate (`hub check`) | Admits it from contract 1.7 | Current source admits supported components with `wasm-components-v1`; the 1.11 policy treats family declarations as disclosures. | | Current source (macOS, Windows, Linux, Android and OpenHarmony) | Included; OpenHarmony uses Pulley | Included, with phase 3 adapters and per-app shared-component loading; iOS excluded. Source inclusion does not establish device acceptance. | | `card-host` | Admits the app; calls answer `no service answers "wasm" on this device` | Also has no `wasm` service. Manifest admission does not make a component runnable there. | -| Releases | Desktop RC4 on macOS/Windows/Linux; also desktop RC2 on macOS/Linux and Home beta.2 | Desktop RC4 includes it on macOS/Windows/Linux; final Mac archive acceptance is linked above. Home beta.2 has no components. | +| Releases | Desktop RC4, RC5 and RC6 on macOS/Windows/Linux; also desktop RC2 on macOS/Linux and Home beta.2 | Desktop RC4, RC5 and RC6 include it on macOS/Windows/Linux; RC5 is the first whose component HTTPS works, the first with `charts.d3@1`, and the first with a component app installed from the public catalog (above); RC6 adds sockets. Home beta.2 has no components. | The recorded command examples below were run on macOS (Apple silicon) with Rust 1.97.1 before the declaration-policy correction, unless marked @@ -296,8 +314,9 @@ always reads from the file itself. ### 5. Call it from the app -RC4 implements this component call path. The recorded SDK examples below -retain their own scope; separately test your exact app in the installed host. +RC4, RC5 and RC6 implement this component call path. The recorded SDK examples +below retain their own scope; separately test your exact app in the installed +host. ```splash host.request("wasm.count", {text: "one two\nthree"}, fn(r){ @@ -334,10 +353,19 @@ An agent tool maps to a component's function as to a module's, with at the stamp: `hub: app dev.example.texttools needs a newer host: wasm-components-v1`. That output belongs to the older gate; see [What the gate checks](#what-the-gate-checks) for the current policy. -- Desktop RC4 includes phases 2 and 3. Test your app in that host, with its - real imports and public host-service calls; the SDK's local fixtures do not - establish your app's behavior or provider authorization. The older module - rehearsal ([Test it](#test-it), steps 2 to 9) has its own recorded scope. +- Desktop RC5 and RC6 include phases 2 and 3 with working HTTPS; RC4 runs + only components whose functions make no requests. Test your app in RC6 (or RC5), + with its real imports and public host-service calls; the SDK's local + fixtures do not establish your app's behavior or provider authorization. + `card-host` cannot drive the functions of an app whose manifest requires + `wasm-components-v1`, and refuses one that requires `host-api-v1`, so + drive either in the compatible release with the shell's Makepad + instrument, in a profile of its own: Repo Radar's + [native acceptance](https://github.com/ymote/octosense-repo-radar/blob/main/tools/NATIVE-ACCEPTANCE.md) scripts that path, from the store install + to a restart, and keeps a receipt that binds the host, the Hub, the catalog + and the source it tested. Never remove a `requires` entry to make a preview + pass. The older module rehearsal ([Test it](#test-it), steps 2 to 9) has + its own recorded scope. The SDK's own tests build its examples and the template with plain cargo for `wasm32-wasip2`, load them in Wasmtime 49 with WASI 0.2 as ADR 0014's @@ -443,8 +471,11 @@ shell, test the exact app and compatible build separately. ### Network **Validation scope:** the SDK tests send requests to a local server in -Wasmtime 49; they do not prove provider calls from an installed app. -OctoSense source includes phase 3; app acceptance needs a compatible build. +Wasmtime 49. Provider calls from an installed app are established by +[Repo Radar](https://github.com/ymote/octosense-repo-radar) on desktop RC5: its component queries `api.github.com` +over HTTPS through this adapter, in the public-store acceptance linked at the +top of this page. RC4 is not a working baseline for component HTTPS +([#471](https://github.com/OctoSense-org/OctoSense/pull/471)); app acceptance needs RC5 or a later compatible build. For HTTP, a component uses `wasi:http` and can reach any host. [TCP, UDP and DNS](#tcp-udp-and-dns) are a separate newer-host path. Under OctoSense's ruling of 8 October 2026, an app's network diff --git a/docs/RUST.zh-CN.md b/docs/RUST.zh-CN.md index 8c5f132d..7f2176e4 100644 --- a/docs/RUST.zh-CN.md +++ b/docs/RUST.zh-CN.md @@ -11,6 +11,8 @@ **[桌面 RC6](../README.zh-CN.md#下载兼容-shell) 已提供套接字支持。** 要求 `wasm.sockets@1` 的应用可以使用普通 TCP、UDP 和 DNS;RC5 不提供该功能。每个应用仍须在其声明的平台上测试。见 [TCP、UDP 和 DNS](#tcpudp-和-dns)。此变更不增加原生库或特权原始 IP 套接字访问。 +**RC5:组件 HTTPS 与图表。** [桌面 RC5](https://github.com/OctoSense-org/OctoSense/releases/tag/desktop-v0.1.0-rc.5) 已发布,源码为 `83d356c2`(2026 年 10 月 11 日)。它是第一个组件 HTTPS 请求能正常工作的发布版本:RC4 在处理第一次 `wasi:http` 请求、选择 TLS provider 时会 panic([#471](https://github.com/OctoSense-org/OctoSense/pull/471))。它还注册了原生 D3 图表,应用可用 `charts.d3@1` 声明对它们的依赖([#470](https://github.com/OctoSense-org/OctoSense/pull/470))。[Repo Radar](https://github.com/ymote/octosense-repo-radar) 是第一个从官方公开目录安装的组件应用:在公开的 RC5 Mac 安装包上,其[公开商店验收](https://github.com/ymote/octosense-repo-radar/blob/main/review/acceptance-public-store-0.1.2.json)通过了 93 项原生检查,覆盖经 `octosense_component::http` 向 GitHub 发出的真实请求、原生图表,以及组件保存在自己存储中、重启后仍在的关注列表。其封存的组件是基于 `serde`、`serde_json`、`semver`、`time` 和 SDK 的普通 Rust,按体积优化后为 496 KB;每次调用最多发出一个请求,请求超时 3 秒,处于 10 秒的调用期限之内,最多解析 2 MiB 响应,因为 SDK 会缓冲整个响应体。它要求 `wasm-components-v1` 与 `host-api-v1`,并声明 `host_api.required: {"charts.d3": 1}`,因此 RC4 拒绝安装它。RC6 保留这一切,并新增套接字(见上文)。 + **RC4 历史基线,保持不变。** [桌面 RC4](https://github.com/OctoSense-org/OctoSense/releases/tag/desktop-v0.1.0-rc.4) 已发布,源码为 `9266b008`,包含组件加载、HTTP、公开宿主服务导入与签名目录中的共享组件。它使用 App Hub 契约 1.11,`capabilities` 与 `network.hosts` 披露用途,不作为执行开关。`requires`、受支持的导入、完整性、配额、应用与账户 scope、实际设备同意、原生写入审核及应用间共享检查继续生效。最终 Mac 归档包与通过 11/11 项 Store/组件检查的候选包字节一致;测试使用真实 GitHub 证明与经管理员证明的私有演练目录,不代表官方公开目录组件安装、真实模型或 Windows/Linux 界面验收。OnePlus 6 组件检查使用隔离的源码测试包,没有升级 Home。你的确切应用仍需单独验收。RC2 与 Home beta.2 只包含核心模块;下方历史观察记录保留原有范围。 | | 核心模块(ADR 0011) | 组件(ADR 0014) | @@ -22,7 +24,7 @@ | App Hub 的准入检查(`hub check`) | 从契约 1.7 起接受 | 当前源码接受带有 `wasm-components-v1` 的受支持组件;1.11 策略把能力族声明视为披露。 | | 当前源码(macOS、Windows、Linux、Android 和 OpenHarmony) | 包含;OpenHarmony 使用 Pulley | 包含第 3 阶段适配器与逐应用共享组件加载;不含 iOS。源码包含不等于真机验收。 | | `card-host` | 接受应用;调用返回 `no service answers "wasm" on this device` | 同样没有 `wasm` 服务。清单通过准入不代表组件能在其中运行。 | -| 发布版本 | 桌面 RC4 的 macOS/Windows/Linux 包;桌面 RC2 的 macOS/Linux 包及 Home beta.2 也包含 | 桌面 RC4 的 macOS/Windows/Linux 包包含;最终 Mac 归档包验收见上文。Home beta.2 不含组件。 | +| 发布版本 | 桌面 RC4、RC5 与 RC6 的 macOS/Windows/Linux 包;桌面 RC2 的 macOS/Linux 包及 Home beta.2 也包含 | 桌面 RC4、RC5 与 RC6 的 macOS/Windows/Linux 包包含;RC5 是第一个组件 HTTPS 可用、第一个提供 `charts.d3@1`、也是第一个有组件应用从公开目录安装的版本(见上文);RC6 新增套接字。Home beta.2 不含组件。 | 下方命令示例在声明策略修正前,曾在 macOS(Apple 芯片)上用 Rust 1.97.1 运行,标注为**未验证**的除外。历史准入输出只证明当时版本行为,不是当前必须取得能力族授权的要求。示例使用 `tools/octo new` 在 `~/apps/my-app` 创建的应用(见 [QUICKSTART §3](QUICKSTART.zh-CN.md#3-创建应用)),id 为 `dev.example.texttools`。 @@ -195,7 +197,7 @@ tools/octo wasm info bundle/fns/text-tools.wasm ### 5. 在应用中调用 -RC4 已实现此组件调用路径。下方既有 SDK 示例保留原有验证范围;须在已安装宿主中单独验证你的确切应用。 +RC4、RC5 与 RC6 已实现此组件调用路径。下方既有 SDK 示例保留原有验证范围;须在已安装宿主中单独验证你的确切应用。 ```splash host.request("wasm.count", {text: "one two\nthree"}, fn(r){ @@ -216,7 +218,7 @@ Agent 工具映射到组件函数的方式与映射到模块函数相同,用 ` - 像第 3 步那样用 `cargo test` 以本机方式测试逻辑。 - `tools/octo run` 在 `card-host` 中启动应用。`card-host` 没有 `wasm` 服务,每次调用都返回 `no service answers "wasm" on this device`。用它检查布局,以及应用在没有函数时显示什么。App Hub `main` 的 `card-host` 是否接受这份清单属于**未验证**(见页首的表格)。 - `tools/octo check` 运行当前 App Hub 准入检查,接受带 `wasm-components-v1` 的受支持组件。历史 #186 之前的运行在写入摘要时停止:`hub: app dev.example.texttools needs a newer host: wasm-components-v1`。这条输出属于旧准入检查;当前策略见[准入检查查看什么](#准入检查查看什么)。 -- 桌面 RC4 包含第 2、3 阶段。请在该宿主中测试应用实际使用的导入与公开宿主服务;SDK 本地测试示例不代表你的应用行为或提供商授权已验证。较早的模块演练([测试](#测试)第 2 到 9 步)保留其自己的记录范围。 +- 桌面 RC5 与 RC6 包含第 2、3 阶段,且 HTTPS 可用;RC4 只能运行函数不发请求的组件。请在 RC6(或 RC5)中测试应用实际使用的导入与公开宿主服务;SDK 本地测试示例不代表你的应用行为或提供商授权已验证。对清单要求 `wasm-components-v1` 的应用,`card-host` 无法驱动其函数;对要求 `host-api-v1` 的应用,`card-host` 会直接拒绝。两者都请在兼容发布版本中、在一个独立的 profile 里用 Shell 的 Makepad instrument 驱动:Repo Radar 的[原生验收](https://github.com/ymote/octosense-repo-radar/blob/main/tools/NATIVE-ACCEPTANCE.md)把这条路径写成了脚本,从商店安装一直到重启,并保留一份把宿主、Hub、目录和所测源码绑定在一起的回执。绝不要为了让预览通过而删除 `requires` 条目。较早的模块演练([测试](#测试)第 2 到 9 步)保留其自己的记录范围。 SDK 自己的测试用普通的 cargo 为 `wasm32-wasip2` 构建示例和模板,像 ADR 0014 的运行时一样在 Wasmtime 49 中以 WASI 0.2 加载它们,并调用每个函数。对第 3 阶段,测试像 OctoSense 的运行时一样链接 `wasi:http`(`wasmtime-wasi-http` 49)和 `octosense:host`,并照搬它的钩子:`http-client` 示例不经任何授权,按地址和按名称向本机的 HTTP/1.1 服务器发请求,发往从不应答的服务器的请求随这次调用结束;`host-services` 示例调用模拟的宿主服务。在 `sdk/rust/` 中运行: @@ -291,7 +293,7 @@ ADR 0014 给组件提供下列 WASI 0.2 接口;第 3 阶段再加上 `octosens ### 网络 -**验证范围**:SDK 测试在 Wasmtime 49 中向本机服务器发出请求,不证明已安装应用能调用真实服务。OctoSense 源码包含第 3 阶段;应用验收须用兼容构建。 +**验证范围**:SDK 测试在 Wasmtime 49 中向本机服务器发出请求。已安装应用能调用真实服务这一点,由 [Repo Radar](https://github.com/ymote/octosense-repo-radar) 在桌面 RC5 上证实:其组件经此适配器通过 HTTPS 查询 `api.github.com`,见本页开头链接的公开商店验收。RC4 不是组件 HTTPS 的可用基线([#471](https://github.com/OctoSense-org/OctoSense/pull/471));应用验收须用 RC5 或更新的兼容构建。 HTTP 使用 `wasi:http`,可以访问任何主机。[TCP、UDP 和 DNS](#tcpudp-和-dns) 是另一个需要较新宿主的路径。按 OctoSense 2026 年 10 月 8 日的裁定,应用的网络声明(`net`、`network.hosts`)在安装时展示,运行时不强制:边界是操作系统和宿主的 API 表面。清单应披露 `net` 供审核;修正后的准入检查可以对遗漏披露警告,但不会因此拒绝: diff --git a/templates/script-app/AGENTS.md b/templates/script-app/AGENTS.md index 561874eb..1697c1ef 100644 --- a/templates/script-app/AGENTS.md +++ b/templates/script-app/AGENTS.md @@ -32,6 +32,18 @@ Windows, run it as `python $OCTO`. (`$OCTO shot 8141 bundle/screenshots/01-main.png` in step 3), the gate refuses the listing; fix every other `[refused]` line before you go on. +If this app has its own Rust component (`components//`, built into +`bundle/fns/.wasm` by `$OCTO wasm build --app .`), the loop above +covers the layout only: `card-host` answers every `wasm.*` call with +`no service answers "wasm" on this device`, and it refuses an app that +requires `host-api-v1`. Test the component's logic natively with +`cargo test --locked` in its crate, then drive the whole app in the +[compatible OctoSense release](https://github.com/OctoSense-org/OctoSense-App-Flow/blob/main/README.md#compatible-shell-download) +with the shell's Makepad instrument, in a profile of its own +([RUST § Test it](https://github.com/OctoSense-org/OctoSense-App-Flow/blob/main/docs/RUST.md#6-test-it)); +Repo Radar's [native acceptance](https://github.com/ymote/octosense-repo-radar/blob/main/tools/NATIVE-ACCEPTANCE.md) is a scripted example. Never +remove a `requires` entry to make a preview pass. + Follow these rules: - Ask only for capabilities a screen uses; declare every `https://` host in