v2.8.1
clockworklabs/SpacetimeDBv2.8.1Aug 12, 2026by rekhoff
AI Summary
A major feature release that brings first-class support for coding agents via the `spacetime mcp` CLI and a dedicated Codex plugin. It also adds default string values for Rust columns.
Key Highlights
- New `spacetime mcp` CLI for coding agents
- SpacetimeDB Codex plugin
- Rust modules can now declare default string values
- Fixes for deadlocks and decompression failures
New Features
- `spacetime mcp` CLI subcommand
- SpacetimeDB Codex plugin
- Rust default string values
- Unity SDK reset methods
Full Release Notes
## Features
### `spacetime mcp` - bring your coding agent into SpacetimeDB
SpacetimeDB now ships a first-class bridge for local coding agents. The new `spacetime mcp` CLI subcommand launches an MCP (Model Context Protocol) server over stdio - exactly how local agents like Codex, Claude, and Cursor expect to connect - and bridges it to SpacetimeDB's HTTP-based MCP route. The `/v1/mcp` route itself now accepts the target database as a per-call tool argument with inherited auth, so there's no per-user database/identity configuration to set up: just point your agent at `spacetime mcp` and go.
This ships alongside a brand-new **SpacetimeDB Codex plugin**, bundling agent skills that teach your assistant SpacetimeDB concepts, the CLI, and idiomatic module/client development across **Rust, C#, TypeScript, C++, Unity, and Unreal**. Install it with:
```bash
codex plugin marketplace add clockworklabs/SpacetimeDB --sparse .agents --sparse codex-plugin
codex plugin add spacetimedb@spacetimedb-plugins
```
MCP server config (used automatically by the plugin):
```json
{
"mcpServers": {
"spacetimedb": {
"command": "spacetime",
"args": ["mcp"]
}
}
}
```
Note: SpacetimeDB MCP is not yet available for Maincloud.
([#5582](<https://github.com/clockworklabs/SpacetimeDB/pull/5582>))
### [Rust] Support default string values
Rust modules can now declare a default value for `string` columns using `#[default(value)]` with a `&'static str`, closing a gap versus other column-default types.
([#5562](<https://github.com/clockworklabs/SpacetimeDB/pull/5562>))
## Bug Fixes
### Fix deadlock in subscription removal (v1 websocket)
`remove_single_subscription` was acquiring the `subscription` lock before the `tx` lock, violating the required lock-ordering convention and causing a deadlock. This path is exclusive to the v1 websocket protocol.
([#5666](<https://github.com/clockworklabs/SpacetimeDB/pull/5666>))
### Fix rows of exactly 1024 bytes getting ignored in C#
`Errno.EXHAUSTED` from `row_iter_bsatn_advance` was incorrectly treated as "no bytes written, iterator done." It is fixed to match the actual contract: `EXHAUSTED` means zero or more bytes were written and the iterator is now done. Rows whose BSATN encoding is exactly 1024 bytes were previously dropped.
([#5621](<https://github.com/clockworklabs/SpacetimeDB/pull/5621>))
### Fix `readUInt8Array` buffer aliasing in the TypeScript SDK
Reading an `array<u8>` column returned a `Uint8Array` view over the row iterator's reused scan buffer instead of an owned copy, so a decoded value could silently reflect a later scan's bytes. `readUInt8Array` now returns an owned copy.
([#5491](<https://github.com/clockworklabs/SpacetimeDB/pull/5491>))
### Handle WebSocket decompression failures in the TypeScript SDK
`WebsocketDecompressAdapter` previously left a decompress rejection (observed on WebKit/iOS gzip frames) as an unhandled promise rejection, silently dropping the frame and stalling the connection. Decompress failures are now caught, logged, and close the socket so existing reconnect handling takes over.
([#5668](<https://github.com/clockworklabs/SpacetimeDB/pull/5668>))
### Fix default column value bugs across languages
New cross-language smoketests for column defaults uncovered and fixed several default-value bugs.
([#5618](<https://github.com/clockworklabs/SpacetimeDB/pull/5618>))
### Fix replication follower resync tracking
`FollowerActor::sync_logs` failed to update its local last-synced offset after a reset, found via local DST testing.
## Unity SDK
### Support disabled Domain Reloading
Added `ResetStaticFields` reset methods to `Log`, `SpacetimeDBNetworkManager`, `RemoteTableHandleBase`, and `DbConnectionBase`, automatically invoked on subsystem init. This prevents stale singleton instances, cached serializers, and test state from carrying over between Play Mode sessions in Unity projects that disable Domain Reloading.
([#5554](<https://github.com/clockworklabs/SpacetimeDB/pull/5554>))
## Internal Cleanup
### C# exported callback IDs changed from `uint` to `int`
Internal cleanup of the C# bindings: exported callback IDs are now `int` instead of `uint`, which is ABI-neutral at the Wasm i32 level and more idiomatic for C#'s int-indexed collections.
([#5529](<https://github.com/clockworklabs/SpacetimeDB/pull/5529>))
## What's Changed
- Create Codex Plugin (adds `spacetime mcp` CLI subcommand) in [#5582](<https://github.com/clockworklabs/SpacetimeDB/pull/5582>)
- [Rust] Allow to supply a default string value in [#5562](<https://github.com/clockworklabs/SpacetimeDB/pull/5562>)
- Deadlock fix: scope down subscription lock in `remove_single_subscription` in [#5666](<https://github.com/clockworklabs/SpacetimeDB/pull/5666>)
- Fix rows of exactly 1024 bytes getting ignored in C# in [#5621](<https://github.com/clockworklabs/SpacetimeDB/pull/5621>)
- Fix: readUInt8Array must copy, not view the reused scan buffer in [#5491](<https://github.com/clockworklabs/SpacetimeDB/pull/5491>)
- TypeScript SDK: handle decompress failures in WebsocketDecompressAdapter in [#5668](<https://github.com/clockworklabs/SpacetimeDB/pull/5668>)
- Smoketests for default values (and fix bugs) in [#5618](<https://github.com/clockworklabs/SpacetimeDB/pull/5618>)
- Implement ResetStaticFields method for Unity instance cleanup in [#5554](<https://github.com/clockworklabs/SpacetimeDB/pull/5554>)
- Update #2149 to post .NET 10 in [#5529](<https://github.com/clockworklabs/SpacetimeDB/pull/5529>)
**Full Changelog**: [v2.8.0...v2.8.1](<https://github.com/clockworklabs/SpacetimeDB/compare/v2.8.0...release/candidate/v2.8.1>)