Commit Graph

10 Commits

Author SHA1 Message Date
Ryan e03b7d7516 Updated C# Name attribute to Accessor (#4306)
# Description of Changes

Implementation of #4295

Convert existing `Name` attribute to `Accessor` to support new Canonical
Case conversation of 2.0

# API and ABI breaking changes

Yes, in C# modules, we no longer use the attribute name `Name`, it
should now be `Accessor`

# Expected complexity level and risk

1

# Testing

- [X] Build and tested locally
- [X] Ran regression tests locally
2026-02-17 01:16:16 +00:00
Tyler Cloutier 46f3e07dfc Fixes issues with --delete-data=on-conflict (#3730)
# Description of Changes

Fixes https://github.com/clockworklabs/SpacetimeDB/issues/3729

I genuinely don't know what came over me.

# API and ABI breaking changes

None

# Expected complexity level and risk

1.5 very straightforward but not strictly trivial

# Testing
Adds automated integration tests (written in Rust and run with `cargo
test`, although note this comment from @matklad about integration tests
for the future
https://internals.rust-lang.org/t/running-test-crates-in-parallel/15639/2):

- [x] Can publish an updated module if no migration is required
- [x] Can publish an updated module if auto-migration is required (with
the yes-break flag true/false)
- [x] Cannot publish if a manual migration is required
- [x] Can publish if a manual migration is required but the user
specified `--delete-data`
- [x] Can publish if a manual migration is required by the user
specified `--delete-data=on-conflict`
- [x] No data deletion occurs if no migration is required and
`--delete-data=on-conflict` is specified

---------

Signed-off-by: Zeke Foppa <196249+bfops@users.noreply.github.com>
Co-authored-by: Zeke Foppa <196249+bfops@users.noreply.github.com>
Co-authored-by: Zeke Foppa <bfops@users.noreply.github.com>
Co-authored-by: Phoebe Goldman <phoebe@clockworklabs.io>
Co-authored-by: John Detter <4099508+jdetter@users.noreply.github.com>
2025-12-04 21:45:41 +00:00
rekhoff 4143c15b08 C# bindings for views (#3585)
# Description of Changes

Updates C# bindings to allow module authors to define `View`s and
`AnonymousView`s using the pattern:
```
[SpacetimeDB.View]
public static ExampleData? GetExampleDataById(ViewContext ctx, uint id)
{
    return ctx.Db.ExampleData.Id.Find(id);
}
	
[SpacetimeDB.View]
public static ExampleData? GetAnonymousExampleDataById(AnonymousViewContext ctx, uint id)
{
    return ctx.Db.ExampleData.Id.Find(id);
}
```
During publishing of a C# module, the views data will be converted into
`RawViewDefV9`

# API and ABI breaking changes

No known breaking changes

# Expected complexity level and risk

2

# Testing

- [X] Locally tested locally adding the above sample pattern to the
`sdks\csharp\examples~\regression-tests\server` test and performing a
`dotnet build` and a `spacetime publish test`, both of which succeeded.

---------

Signed-off-by: Jason Larabie <jason@clockworklabs.io>
Co-authored-by: Jason Larabie <jason@clockworklabs.io>
2025-11-11 12:01:44 -05:00
rekhoff 833f750c12 Uncommented out 'delete by index' test code (#3156)
# Description of Changes

Uncommented out code from test, in order to have "delete row by index"
test of C# module code ran.
This is the implementation of a fix for issue
https://github.com/clockworklabs/SpacetimeDB/issues/2233

# API and ABI breaking changes

None

# Expected complexity level and risk

1

# Testing

- [X] Ran `dotnet run` and `dotnet test`, both returned no errors.
2025-08-26 21:19:42 +00:00
Zeke Foppa b9d30991f1 Fix remaining LICENSE files (#3193)
# Description of Changes

Apparently, I missed several license files in #3002. I'm not sure what
method I was using to find them, but apparently it was insufficient.

**This replaces all empty `LICENSE` files with an explicit (symlink to)
BSL license, and all apache licenses with symlinks to the root apache
license.** This PR does not intentionally change any license terms, so
if you see one that changed, **it's a mistake**.

# API and ABI breaking changes

None

# Expected complexity level and risk

1

# Testing

```bash
$ find . -name '*LICENSE*' -type f | grep -v '\.meta$'
./crates/sqltest/standards/LICENSE # this one is an external library that we are not allowed to re-license
./LICENSE.txt # this is the root license
```

---------

Co-authored-by: Zeke Foppa <bfops@users.noreply.github.com>
2025-08-22 19:36:47 +00:00
Viktor Szépe f6da9e1f5f Fix typos (#2812)
Signed-off-by: Viktor Szépe <viktor@szepe.net>
2025-06-04 16:33:32 +00:00
Mario Montoya 04fd294627 Add missing LICENSE (#2319) 2025-02-28 14:32:59 +00:00
Mario Montoya 32e24b4095 Add README.md to all modules in SpacetimeDB/modules describing their usage (#2282) 2025-02-19 17:03:34 +00:00
Phoebe Goldman aedc601145 Rename Address to ConnectionId (#2220)
Signed-off-by: Phoebe Goldman <phoebe@goldman-tribe.org>
Co-authored-by: James Gilles <jameshgilles@gmail.com>
Co-authored-by: Tyler Cloutier <cloutiertyler@users.noreply.github.com>
2025-02-10 00:40:16 +00:00
Tyler Cloutier e54a28584a Standardized module names and added module-test-cs based on module-test (#2232) 2025-02-09 05:58:19 +00:00