clockworklabs / clockworklabs/SpacetimeDB

C#/Unity SDK - Make fields of generated row types `{ get; private set; }`

Open
#3,046 0 comments 0 reactions 1 assignee View on GitHub

@rekhoff is already working on this.

Since Jul 1, 2025.

api-break
Dominant language
Rust
Stars
25.2k
Forks
1.1k
Avg merge
2d 7h
Merged PRs (30d)
46

Description

This is technically an API break, but if the users are ever modifying row classes directly:

  • They don't get update callbacks
  • No message is sent to the server
  • The changes will be overwritten on a server update

Modifying rows is statically impossible in the Rust SDK because & references are used.

We should make the fields non-modifiable to match the rust SDK. This will only break users who were using the API incorrectly.

This will require changes in the SpacetimeDB codegen crate.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.