clockworklabs / clockworklabs/SpacetimeDB
Implement type-safe primary keys across SDKs
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 25.2k
- Forks
- 1.1k
- Avg merge
- 2d 7h
- Merged PRs (30d)
- 46
Description
This issue tracks reimplementing the work from stale PR #3476, which has been closed because it is too far out of date to merge directly.
Original pull request
- PR #3476: Implemented type-safe primary keys
- Original author: @egormanga
What the original PR was trying to do
Description of Changes * Note: based on (and includes) 2957. For a table like this: generates a type like that: Yet to make it treat the type as Identity. Perhaps a trait is needed instead of a newtype. Usage: * Resolves 3472. API and ABI breaking changes None. Expected complexity level and risk 3? Testing - [x] Module compiles - [x] Module publishes
Closure context
- I think we need to have a think about this one in the context of other languages. As written this would make Rust types inconsistent with the types in the other languages. Much like in #2957 we'd need to address this for all languages.
Reimplementation notes
- Reimplement this work on top of current
masterin a new PR. - Keep the original PR linked as historical context and as a source of useful implementation ideas where still relevant.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing PR #3476 and comparing its approach with current master and the other SDKs. Identify the SDK-specific representations and compatibility constraints before defining the cross-language design. Done means a new PR reimplements type-safe primary keys consistently across all affected SDKs, with the relevant modules compiling and publishing as in the original PR.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- databases
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 30/100