clockworklabs / clockworklabs/SpacetimeDB

Create `st_module` `module_version` column for module writers to manage semantic versioning

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

@kazimuth is already working on this.

Since Sep 25, 2024.

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

Description

Version the codegen and send that along the messages, modules, etc similar to:

API: 1.1.2

Also, when SATS encoding prepared this plus a hash of the original schema

[("1", AlgebraicType::I32)] == [API: 1.1.2, Hash: 0x1..]

so we can be sure the decoding match the supplied schema:

let original = [("1", AlgebraicType::I32); [AlgebraicValue::I32(1)] 
//imagine this was done in this specific ABI
let schema = api_1_1_2(original) == [API: 1.1.2, Hash: 0x1..]

let encoded = encode(original) == [API: 1.1.2, Hash: 0x1.., Data: 1]

//and the ABI break
let schema = api_1_0_1(original) == [API: 1.0.1, Hash: 0x1..]

let decoded = decode(schema, [AlgebraicValue::I32(1)]) != encoded

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.