Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 4 additions & 22 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,26 +7,6 @@ on:
branches: [main]

jobs:
wit-immutability:
name: WIT frozen-file immutability
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Determine base ref
id: base
run: |
if [[ "${{ github.event_name }}" == "pull_request" ]]; then
echo "ref=origin/${{ github.base_ref }}" >> "$GITHUB_OUTPUT"
else
echo "ref=HEAD~1" >> "$GITHUB_OUTPUT"
fi

- name: Check frozen-file immutability
run: scripts/lint-wit-immutability.sh ${{ steps.base.outputs.ref }}

wit-parses:
name: WIT files parse
runs-on: ubuntu-latest
Expand All @@ -37,8 +17,10 @@ jobs:
run: cargo install --locked wasm-tools

- name: Parse every host/*.wit file
# Stages each host/*.wit alongside vendored deps/ (wasi-io) +
# sibling host/ files so cross-package `use` clauses resolve.
# Stages each host/*.wit alongside its sibling host/ files so
# cross-package `use` clauses resolve. There are no vendored
# external WIT packages — the Astrid host ABI is self-contained
# (`astrid:*` only, no `wasi:*` dependency).
# interfaces/*.wit files are not validated here — they cross-
# reference each other and wasm-tools 1.x can't topo-sort deps/
# in a single pass; downstream SDK builds (cargo-component / wkg)
Expand Down
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ Each domain is its own package, frozen at a per-file version. A capsule imports
| File | Package | Description |
|------|---------|-------------|
| `host/fs@1.0.0.wit` | `astrid:fs@1.0.0` | Filesystem operations within the workspace boundary — whole-file IO, file handles with positional read/write, metadata, canonicalize, read-link, hard-link. |
| `host/io@1.0.0.wit` | `astrid:io@1.0.0` | Foundation I/O — three interfaces. `error`: downcastable error resource carried by stream errors. `poll`: Astrid-owned `pollable` resource for readiness multiplexing across heterogeneous host resources. `streams`: `input-stream` / `output-stream` resources with read / write / skip / flush / `splice` for high-throughput host-side byte movement. Shape mirrors `wasi:io@0.2.0` but Astrid-owned — every operation is audited, principal-scoped, cancellable, and quota-bounded. |
| `host/ipc@1.0.0.wit` | `astrid:ipc@1.0.0` | Publish/subscribe IPC event bus. |
| `host/uplink@1.0.0.wit` | `astrid:uplink@1.0.0` | Inbound message ingestion from external platforms. |
| `host/kv@1.0.0.wit` | `astrid:kv@1.0.0` | Per-capsule, per-principal key-value storage with atomic compare-and-swap and paginated key listing. |
Expand Down Expand Up @@ -73,7 +74,7 @@ To evolve a package:
4. Leave the existing frozen file untouched.
5. The kernel registers both versions in its linker (`bindings::ipc_v1_0::add_to_linker` and `bindings::ipc_v1_1::add_to_linker`) so old and new capsules both load.

CI enforces this via `scripts/lint-wit-immutability.sh` — any PR that modifies or deletes a published `*@X.Y.Z.wit` file fails the build.
The rule is currently a documented convention rather than a CI gate. The automated frozen-file check was retired during pre-adoption iteration (no SDK or capsule is bound to `@1.0.0` yet, so in-place amendments don't break anyone). Once a real downstream consumer ships against a versioned file, re-enable the check (the original script lives in git history) so accidental edits surface in review.

See [RFC: Host ABI](https://github.com/unicity-astrid/rfcs/pull/22) for the full design (per-domain packages, multi-version kernel registration, frozen-file rule) and [issue #750](https://github.com/unicity-astrid/astrid/issues/750) for the motivating bug.

Expand Down
34 changes: 0 additions & 34 deletions deps/wasi-io/error.wit

This file was deleted.

41 changes: 0 additions & 41 deletions deps/wasi-io/poll.wit

This file was deleted.

262 changes: 0 additions & 262 deletions deps/wasi-io/streams.wit

This file was deleted.

Loading
Loading