Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pull] master from clockworklabs:master #2

Open
wants to merge 380 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
380 commits
Select commit Hold shift + click to select a range
5cc05b1
NFC: few more C# shorthand syntax conversions (#1176)
RReverser Apr 30, 2024
fd44242
1. Add `Hash for RowRef` + make it consistent with PV. (#1163)
Centril Apr 30, 2024
27a7b67
NFC: reuse common parts of C# generation (#1187)
RReverser Apr 30, 2024
e144c40
Redefine FieldName as `(TableId, ColId)` (#1165)
Centril Apr 30, 2024
2c07b3b
`impl PartialEq<ProductValue> for RowRef` (#1164)
Centril Apr 30, 2024
b55121c
use a custom FixedBitSet + optimize Page::iter_fixed_len (#1160)
Centril Apr 30, 2024
0142e14
Implement `RelValue: Eq + Hash` (#1107)
Centril Apr 30, 2024
e526c8c
Fix soundness hole in `Table::delete` + don't make & immedately drop …
Centril Apr 30, 2024
6810821
Add PR status check that fails unless based on `master` (#1180)
bfops May 1, 2024
7c52ef5
clarify cost of dropping the updates in eval_incr (#1192)
Centril May 2, 2024
e258262
perf(`JoinInner`): use AVs for keys instead of PVs (#1194)
Centril May 2, 2024
484ba82
Make `Page` always fully init (#1193)
gefjon May 2, 2024
165f750
Remove C# GetArgsAsObjectArray (#1188)
RReverser May 3, 2024
9ce8fc8
feat(1168): Track subscription query duration for each reducer (#1195)
joshua-spacetime May 3, 2024
fcc326b
Fix unsoundness in `AlgebraicValue::type_of` by making it partial (#1…
Centril May 3, 2024
6dce129
From.{join => joins} + remove Option layer + Remove RelOps::try_fold …
Centril May 7, 2024
1be912b
subscription benches: reorder footprint fields (#1209)
Centril May 7, 2024
fe44011
C#: rename DbEventArgs to ReducerContext (#1191)
RReverser May 8, 2024
3b754f1
Bump to Rust 1.78 (#1205)
coolreader18 May 8, 2024
b275dbf
`spacetime build` uses `--project-path` param (#1212)
jdetter May 9, 2024
78696e5
remove some dead code (#1210)
Centril May 10, 2024
4e444bd
CrudExpr::{Delete, Insert, Update}: only DbTables are possible, so cl…
Centril May 10, 2024
e252b0c
Remove RowUpdate event from C# (#1190)
RReverser May 10, 2024
125ca70
Switch to a better API for tagged enums for C# (#1177)
RReverser May 10, 2024
9a827f2
remove a few dead impls (#1214)
Centril May 13, 2024
61613ca
commitlog: Allow folds to not allocate `Mutations` values (#1215)
kim May 13, 2024
669d487
Fix #1180: Add PR status check that fails unless based on master (#1213)
bfops May 13, 2024
4cdb660
Split up #735: `auth.rs` refactors (#871)
bfops May 13, 2024
f6573c4
Create a lockfile when opening config files (#1196)
gefjon May 13, 2024
c7f191f
Bump version to 0.9.0 (#1055)
bfops May 13, 2024
52c6df6
Add CODEOWNERS for `rust-toolchain.toml` (#1221)
bfops May 14, 2024
b3ea0f5
Fix select * from * (#1218)
coolreader18 May 14, 2024
08ecaf8
[bfops/cli-identity-refactor]: do thing (#1169)
bfops May 14, 2024
7d41e76
Add CODEOWNERS for `LICENSE.txt` (#1225)
bfops May 14, 2024
70de033
Add `CODEOWNERS` for `CODEOWNERS` (#1226)
bfops May 14, 2024
8ab55d2
`spacetime publish`: Add confirmation for `-c` (#1038)
bfops May 14, 2024
f13a143
Make identity naming more consistent + fix bugs (#1140)
jdetter May 14, 2024
401ffe2
feat(1229): Double client channel capacity (#1230)
joshua-spacetime May 14, 2024
5154f79
to_bsatn_extend/vec: use uninit instead of zeroed buffer (#1204)
Centril May 14, 2024
9546a22
refactor compile_read_only_query: dedup SideEffect errors (#1235)
Centril May 15, 2024
5bf6b6c
add compile_join_with_diff_col_names test (#1238)
Centril May 15, 2024
d08e984
Always send TransactionUpdate to the sender (#1111)
drogus May 16, 2024
0c0567e
row_count field to table (#1242)
Shubham8287 May 17, 2024
267cf65
simplify MutTxId::table_exists (#1246)
Centril May 17, 2024
c665503
Remove unreachable branches from C# generate (#1247)
RReverser May 18, 2024
0b89165
- Table::get_fixed_row -> RowRef::get_row_data (#1250)
Centril May 20, 2024
d188f96
move static bsatn layout to module + harden test (#1254)
Centril May 20, 2024
e109385
remove BTreeIndex::name again (#1251)
Centril May 20, 2024
f0c182e
Atomically downgrade lock when committing tx to prevent deadlock (#1252)
coolreader18 May 20, 2024
4759584
Slightly better logging of sled errors, pending sledectomy (#1248)
kazimuth May 20, 2024
91f7e8c
add PageHeader::unmodified_hash, a BLAKE3 hash for snapshotting (#1249)
Centril May 20, 2024
ebc9218
privatize Table::row_layout + related BTreeIndex refactoring (#1262)
Centril May 20, 2024
2de1475
core: Collapse DBIC into HostController (#1186)
kim May 21, 2024
edbca25
core: Reserve sequence range for system tables (#1265)
kim May 22, 2024
670625e
add fn ColList::last(&self) -> ColId (#1267)
Centril May 22, 2024
9257208
1. Privatize `st_*_schema` functions, only used in system_tables() no…
Centril May 22, 2024
6b1a3d3
Module hotswapping (#1147)
coolreader18 May 22, 2024
552b18b
Consistent filtering rules for Rust bindings (#1280)
RReverser May 22, 2024
471f4ff
recv-style abi (#1002)
coolreader18 May 22, 2024
88a8ada
feat(1231): Basic query cardinality estimation (#1273)
joshua-spacetime May 23, 2024
25513b3
Simplify `btree_index` module with more idiomatic Rust (#1285)
Centril May 23, 2024
48a2b98
Disconnect dangling clients (#1132)
kim May 23, 2024
93b9d76
CI workflows support `workflow_dispatch` event (#1289)
bfops May 24, 2024
8c3fa75
Remove `incremental-joins.md` (#1296)
bfops May 24, 2024
0bf5d74
Fix `workflow_dispatch` for ci.yml (#1295)
bfops May 24, 2024
7c90990
Add table smoketest + more smoketest logging (#1272)
kazimuth May 24, 2024
8ecee76
Shub/st connected clients (#1288)
Shubham8287 May 24, 2024
55b7cbe
Let ProgramStorage::external be async (#1291)
coolreader18 May 24, 2024
1f23316
due cleanup (#1301)
Shubham8287 May 27, 2024
8096ab6
fix(1297): `spacetime logs -f` should not start at the very beginning…
bfops May 28, 2024
0e74bee
`merge_apply_inserts/deletes`: do metrics work once per table, not pe…
Centril May 28, 2024
f5a13b6
Consistent filtering in Rust client + minor fixes (#1275)
RReverser May 28, 2024
a7c7575
Implement consistent filtering rules for C# modules (#1282)
RReverser May 28, 2024
307dfee
Update C# codegen to consistent filtering rules (#1277)
RReverser May 28, 2024
ac0c097
Implement consistent filtering rules for TypeScript (#1276)
RReverser May 28, 2024
be74474
CLI - Fix `Lockfile` error message format strings (#1302)
bfops May 28, 2024
3b33f22
CLI - Drop Config lock earlier for `spacetime logs` (#1303)
bfops May 28, 2024
c8225db
1. Reduce visibilities, preparing to extract datastore crate (#1306)
Centril May 28, 2024
2c3fc66
Commitlog: panic on fsync failure (#985)
kim May 28, 2024
4ac49e5
execution_set.check_auth(...) on initial subscription (#1274)
Centril May 28, 2024
2d045b6
fn (walk_)sources: use internal iteration to avoid allocations (#1304)
Centril May 28, 2024
0bc42bf
Bump version to 0.9.3 (#1224)
bfops May 29, 2024
6512f35
feat(1231): Add a configurable row limit for queries (#1293)
joshua-spacetime May 30, 2024
c76c3a0
NFC: use record struct for auto-equality in C# (#1318)
RReverser May 31, 2024
9e1e66f
Fix FilterBy regression in C# (#1309)
RReverser May 31, 2024
24d1750
Bump ABI version for C# AOT (#1311)
RReverser May 31, 2024
f8beb69
Implement new rand api (#1283)
coolreader18 May 31, 2024
cf4b9aa
metric for table size (#1319)
Shubham8287 May 31, 2024
6384452
Automated bot tests (#1255)
kazimuth May 31, 2024
74bcecd
Restrict multi-col index scans to `=` (`OpCmp::Eq`) on all columns …
Centril Jun 1, 2024
a854945
Re-add execute_sql_mut_tx (#1313)
coolreader18 Jun 3, 2024
5e47b61
Tables only become public explicitly via `#[spacetimedb(table(public)…
Centril Jun 3, 2024
f6b39c0
`IndexJoin`/`JoinInner`: store `ColId` (#1166)
Centril Jun 3, 2024
2b66851
More trace logs for TX locking (#1253)
bfops Jun 3, 2024
89aecd1
Split `ColumnOp` into one with row indices and one with `FieldName` &…
Centril Jun 3, 2024
be9c958
Flatten ColumnOp so that we box less (#1234)
Centril Jun 3, 2024
18aa1d4
Fix commitlog `fold_transactions_from` ignoring requested offset (#1330)
gefjon Jun 3, 2024
da23401
Jeremie/notify sql (#1198)
lcodes Jun 3, 2024
a214f78
Impl `Serialize`, `Deserialize` for `Page` (#1335)
gefjon Jun 4, 2024
db34ff6
Create new crate `fs-utils`; move `Lockfile` and `create_parent_dir` …
gefjon Jun 4, 2024
697a581
Make both TX offset counters agree (#1332)
gefjon Jun 4, 2024
ff851ae
commitlog: Make bitflip test a proptest (#1333)
kim Jun 5, 2024
f08644f
make update_database insensitive to table access changes (#1338)
Centril Jun 5, 2024
f9cc84e
Define `DirTrie`, a git-like on-disk object store (#1336)
gefjon Jun 5, 2024
8c5f40d
Add the `snapshot` crate, which implements snapshotting at a low leve…
gefjon Jun 5, 2024
b06b2e5
Fix bug with `Lockfile` sticking around (#1341)
bfops Jun 5, 2024
335c5b6
chore: fix typos (#1241)
xiaoxianBoy Jun 6, 2024
8f3f6bd
Fix `Config.save` failing if `/tmp` is on a different filesystem (#1346)
bfops Jun 6, 2024
b3339c8
feat(1329): System table for system variables (#1342)
joshua-spacetime Jun 6, 2024
4af892a
[bfops/update-quickstart]: do thing (#1348)
bfops Jun 6, 2024
d1033b5
Shared C# codegen for BSATN (#1312)
RReverser Jun 7, 2024
a543994
Prune bindings deps (#1290)
coolreader18 Jun 7, 2024
61ee5de
feat: System table based slow query logging (#1350)
joshua-spacetime Jun 7, 2024
b525247
Add Jenkinsfile to run internal automation (#1232)
kurtismullins Jun 9, 2024
ccaad88
fix(1353): Remove underscore based table access checks (#1354)
joshua-spacetime Jun 10, 2024
1044ebc
core: Store address, owner and program bytes in st_module (#1305)
kim Jun 10, 2024
c2831d0
test(1329): Row limit from system table (#1355)
joshua-spacetime Jun 10, 2024
d11c83e
Add explicit parameter for table visibility (#1359)
RReverser Jun 10, 2024
2d09485
Bump version to 0.10.0 (#1349)
bfops Jun 10, 2024
114aa99
Fix output of binary, Identity, Address for `SQL` output and the 'Dis…
mamcx Jun 10, 2024
6c45e76
Integrate snapshotting into core (#1344)
gefjon Jun 11, 2024
299789a
core: Determine dangling clients from `st_clients` (#1366)
kim Jun 11, 2024
0fa94ce
durability: Skip fsync if nothing changed (#1360)
kim Jun 11, 2024
cb2fbb9
[C#] Add Roslyn shapshot tests (#1399)
RReverser Jun 11, 2024
2ea93c2
chore: Remove max value metrics (#1402)
joshua-spacetime Jun 12, 2024
0b99e10
[NFC] [C#] Minor simplifications to type checks in Roslyn codegen (#1…
RReverser Jun 12, 2024
e73ea79
Add Option SDK tests (#1405)
RReverser Jun 12, 2024
2b7b19e
[C#] [NFC] Use semantic model's type where possible (#1401)
RReverser Jun 12, 2024
6e052cb
Fix auth regression (#1413)
coolreader18 Jun 12, 2024
220ff47
Remove unused file table.rs (#1417)
Centril Jun 13, 2024
220c488
fix(1409): Counter metric names (#1411)
joshua-spacetime Jun 13, 2024
44832f2
chore: Remove already tracked subscription counter (#1412)
joshua-spacetime Jun 13, 2024
9e0d1c9
refactor: Record txn-level metrics in a single utility (#1414)
joshua-spacetime Jun 13, 2024
4b7eff6
Generate tagged enums in C# client code (#1421)
RReverser Jun 13, 2024
910f605
Include BSATN.Codegen in nuget pack (#1424)
kurtismullins Jun 13, 2024
e808c1e
`TableDef`: clarify `generated_*` methods (#1419)
Centril Jun 13, 2024
814dd5b
Add small 'realistic' workload benchmark integration test (#714)
mamcx Jun 13, 2024
66112bb
Impl subscribe subcommand & subscription smoketests (#1343)
coolreader18 Jun 14, 2024
b1442fc
HACK: Tweak `schema_updates` to allow adding/removing non-unique indi…
Centril Jun 14, 2024
cceb8c0
Update tools/publish-crates.sh (#1426)
bfops Jun 14, 2024
19b7815
refactor: Reconfigure histogram buckets for certain metrics (#1436)
joshua-spacetime Jun 14, 2024
8a3364e
perf(1351): Add a row count metric for subscriptions (#1435)
joshua-spacetime Jun 14, 2024
1d89643
Implement the module rng proposal for C# (#1425)
RReverser Jun 17, 2024
dcc70b8
Bump version to 0.10.1 (#1443)
bfops Jun 17, 2024
c94a551
Roslyn cacheability testing and fixes (#1420)
RReverser Jun 18, 2024
137f26d
Restructure NuGet packaging (#1440)
RReverser Jun 18, 2024
a93bd49
Fix index removal and additions + add smoketest (#1444)
Centril Jun 19, 2024
384591a
core: Downgrade host log verbosity (#1446)
kim Jun 19, 2024
60c438d
Smoketest auto-disconnect after restart (#1367)
kim Jun 20, 2024
c19c0d4
core: Simplify custom bootstrap (#1404)
kim Jun 21, 2024
4c0185d
core: Replace host scheduler on update (#1453)
kim Jun 24, 2024
637a654
CLI - Update help text suggesting `spacetime server fingerprint` to h…
bfops Jun 24, 2024
8be8fc1
Fix inconsistent auth/identity creation (#735)
coolreader18 Jun 25, 2024
81085b0
Fixed exceptions in C# SDK when someone disconnects or when a transac…
SteveBoytsun Jun 26, 2024
2399e74
Ensure MacOS builds from CI are executable (#1462)
kurtismullins Jun 26, 2024
e536a6d
Automated Discord post when a PR merges (#1470)
bfops Jul 1, 2024
b2eb08c
Fix C# module smoketests (#1475)
bfops Jul 4, 2024
c8259bf
smoketests: Add test for module hotswapping (#1403)
kim Jul 8, 2024
cbff725
`ColList`: preserve list order on `list.push(..)` (#1474)
Centril Jul 8, 2024
e913e8c
CLI: Put some common params in a central place (#1484)
bfops Jul 9, 2024
2ad91b6
Implement a temporary type check validation on sql compiling (#1456)
mamcx Jul 9, 2024
f91dcda
Make some commitlog helpers public (#1390)
lcodes Jul 9, 2024
80b6466
Adding benchmark for deserialize json & product value (#1035)
mamcx Jul 10, 2024
3266aa4
CLI: Use `--server` and `--identity` args consistently instead of ano…
bfops Jul 10, 2024
595181e
Fix running 'cargo test' in crates/lib (#1478)
kazimuth Jul 11, 2024
6f0f20b
Restructure C# SpacetimeDB runtime (#1455)
RReverser Jul 12, 2024
10b151b
Protobufectomy: server (#1077)
coolreader18 Jul 12, 2024
3934485
refactor(1494): Remove SQL DDL per 1.0 SQL spec (#1499)
joshua-spacetime Jul 12, 2024
75acefc
C# smoketests use `nuget.config` (#1500)
bfops Jul 15, 2024
50b050f
CI - SpacetimeDB PRs run the C# SDK tests (#1503)
bfops Jul 15, 2024
276387d
Timer Table Implementation (#1449)
Shubham8287 Jul 16, 2024
2b291b0
CI - Post-to-discord workflow only fires if the PR merged to `master`…
bfops Jul 16, 2024
cadf986
Return empty success from /identity GET (#1491)
lcodes Jul 16, 2024
3e6f91b
Moving recovery code APIs under /identity and using POST (#1492)
lcodes Jul 17, 2024
04a7508
`Table::is_row_present`: don't panic (#1526)
gefjon Jul 17, 2024
f81f2a7
Move `db` module from `spacetimedb_sats` to `spacetimedb_lib` (#1479)
kazimuth Jul 17, 2024
ee7b096
Ignore some sequence allocation mismatches when checking for compatib…
gefjon Jul 18, 2024
0ed26a7
Add some helper scripts (#1501)
kazimuth Jul 18, 2024
7e421bb
Drain scheduler Actor channel before start (#1529)
Shubham8287 Jul 18, 2024
8338b53
commitlog: Fix single-commit bitflip test (#1528)
kim Jul 19, 2024
417adb8
Bump version to 0.11.0 (#1531)
bfops Jul 22, 2024
1d26575
ST sequences: respect allocated amount on restart (#1532)
gefjon Jul 24, 2024
e9daae9
Don't run bot tests on every master commit whoops (#1441)
kazimuth Jul 24, 2024
45b2cee
Move schemas to `schema` crate, rename `Def` to `RawDefV8` (#1498)
kazimuth Jul 24, 2024
1ce62da
`spacetime generate` - make the source args optional (#1537)
bfops Jul 24, 2024
30c000f
C#: ignore fields in partial declaration not marked with BSATN attrib…
RReverser Jul 25, 2024
afddf01
ABI BREAK: Add versioning for RawModuleDef (#1518)
kazimuth Jul 25, 2024
7500ea3
C#: remove `using SpacetimeDB.ClientApi;` (#1546)
RReverser Jul 25, 2024
769992c
broadcast schedule table deletion (#1547)
Shubham8287 Jul 26, 2024
cd5e50a
`spacetime server add` - Remove trailing `/`s from server URIs (#1552)
bfops Jul 26, 2024
216ed04
core: Singular system table names (#1550)
kim Jul 26, 2024
c046c0b
Add ErrorStream combinator (#1543)
kazimuth Jul 26, 2024
3451cab
Use latest C# in BSATN.Runtime (#1548)
RReverser Jul 26, 2024
8508207
table: Make `with_mut_schema` clone-on-write (#1530)
kim Jul 29, 2024
e5cfb1e
Fix flaky subscription smoketests (#1536)
bfops Jul 29, 2024
21058e0
core: Start system table ids at 1 (#1544)
kim Jul 30, 2024
4ffeff7
Remove support for the `update` reducer (#1557)
kim Jul 31, 2024
5c585b6
Get rid of python SDK (#1561)
Centril Aug 1, 2024
711a671
client-api: Remove publisher address (#1564)
kim Aug 5, 2024
db16a09
Minor NFC improvements to C# Roslyn codegen (#1562)
RReverser Aug 6, 2024
3340cee
SATS: Flatten `AlgebraicType`, getting rid of `BuiltinType` (#1559)
Centril Aug 6, 2024
b7072a3
Updating the change date in anticipation of the anniversary (#1574)
cloutiertyler Aug 7, 2024
d6a215d
Update README.md (#1575)
cloutiertyler Aug 7, 2024
a2f812b
Make `schema` crate publishable (#1569)
bfops Aug 7, 2024
e3333ea
`Typespace::is_nominal_normal_form` (#1549)
kazimuth Aug 7, 2024
1b48555
Add lib::db::{column_ordering, raw_def::v9} (#1542)
kazimuth Aug 7, 2024
cbacc44
Change ResolveRefs to return a Result rather than an Option (#1565)
kazimuth Aug 7, 2024
1e8e18d
Add support for `I256` and `U256` (#1477)
Centril Aug 8, 2024
ba4546c
core: Use `Program` instead of `(Hash, Box<[u8]>)` (#1558)
kim Aug 9, 2024
2b7b9ff
Bump version to 0.12.0 (#1578)
bfops Aug 9, 2024
01d4ed1
Fix [iu](128|256) BSATN implementations in C# (#1582)
RReverser Aug 13, 2024
09f96ff
C#: disable verbose test output in console (#1570)
RReverser Aug 13, 2024
7057d9f
Add helpers and change `CollectAllErrors` to be more composable (#1586)
kazimuth Aug 13, 2024
b1f80e0
Preliminary Identifier validation (#1584)
kazimuth Aug 14, 2024
6a08674
Allow empty `ColList` (#1588)
Centril Aug 15, 2024
2c38913
[CI] Do not use branch names when publishing container images (#1583)
kurtismullins Aug 15, 2024
16ecf99
Verify Unity compatibility in the shared C# codegen (#1576)
RReverser Aug 15, 2024
96b8d43
Fix builds for MacOS amd64 platform (#1598)
kurtismullins Aug 17, 2024
1ca9b1a
[WASM ABI 1.0] Change `ColId` from `u32` to `u16` (#1597)
Centril Aug 19, 2024
3be5c83
[WASM ABI 1.0] `__call_reducer__` receives Identity & Address by valu…
Centril Aug 19, 2024
9ea5a2f
[WASM ABI 1.0] impl `__call_reducer__` using `bytes_source_read` (#1609)
Centril Aug 20, 2024
9e178bd
Placate some clippy errors in `snapshot` (#1611)
kazimuth Aug 20, 2024
8282b67
fix: Always remember to release a read only tx (#1613)
joshua-spacetime Aug 20, 2024
9f1b6dc
NFC: enforce style for C# locally and on CI (#1567)
RReverser Aug 21, 2024
747eb71
Make `ScheduleAt` special + `Typespace::is_valid_for_client_code_gene…
kazimuth Aug 22, 2024
9380eb6
Dedup schedueler queue (#1587)
Shubham8287 Aug 22, 2024
4e530a5
Updated docker internal port to 3000 (#1626)
jdetter Aug 23, 2024
c577d50
Add volatile_nonatomic_schedule_immediate (#1612)
coolreader18 Aug 23, 2024
b4c7c89
NFC: use record for BigInt equality and hash (#1633)
RReverser Aug 26, 2024
7a071ac
smoketests: Test unauthorized publish without -c (#1632)
kim Aug 27, 2024
4c086fe
[WASM ABI 1.0] impl `__call_reducer__` & `__describe_module__` using…
Centril Aug 27, 2024
6e6bee2
ABI v9 validation code (#1572)
kazimuth Aug 27, 2024
c88a6ce
Fix ptr mutability of some new C# FFIs (#1645)
RReverser Aug 27, 2024
1dd1e63
WASM ABI: implement `row_iter_bsatn_advance` & `row_iter_bsatn_close`…
Centril Aug 27, 2024
2b69583
WASM ABI: `get_table_id` -> `table_id_from_name` (#1634)
Centril Aug 27, 2024
c26c658
WASM ABI: add `datastore_table_row_count` (#1636)
Centril Aug 27, 2024
bba3572
[WASM ABI 1.0] Fix `bytes_source_read` (#1646)
kim Aug 28, 2024
98faf7d
Add backwards-compatible validation for RawModuleDefV8. (#1606)
kazimuth Aug 29, 2024
2be4215
Allow converting new ModuleDef to old TableSchema (#1630)
kazimuth Aug 29, 2024
f7ae920
Fix flaky smoketest due to race condition in subscribe (#1656)
coolreader18 Aug 29, 2024
8ee1de6
Update SQL AST in accordance with the SQL spec (#1623)
mamcx Aug 29, 2024
49f366f
WASM ABI: `iter_start` -> `datastore_table_scan_bsatn` (#1637)
Centril Sep 2, 2024
b625694
WASM ABI: `delete_by_rel` -> `datastore_delete_all_by_eq_bsatn` (#1638)
Centril Sep 2, 2024
dd65d6d
Add edition to .rustfmt.toml (#1663)
gefjon Sep 4, 2024
69e881c
bindings-csharp: pass `address_1` (#1621)
Centril Sep 4, 2024
68e3565
C#: split table codegen logic from type codegen logic (#1573)
RReverser Sep 5, 2024
da71d0f
WASM ABI: `insert` -> `datastore_insert_bsatn` & impl new semantics (…
Centril Sep 5, 2024
df5ef6c
WASM ABI: implement console ABIs (#1664)
Centril Sep 5, 2024
2cccac4
C# module benchmarks (#1679)
RReverser Sep 6, 2024
607f7ce
Auto-generate C# ModuleDef bindings from Rust (#1680)
RReverser Sep 9, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
**/module_bindings/** linguist-generated=true eol=lf
*.verified.cs linguist-generated=true eol=lf
/crates/bindings-csharp/Runtime/Internal/Autogen/*.cs linguist-generated=true
4 changes: 4 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/crates/core/src/db/datastore/traits.rs @cloutiertyler
/rust-toolchain.toml @jdetter @cloutiertyler
/.github/CODEOWNERS @cloutiertyler
LICENSE.txt @cloutiertyler
8 changes: 8 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,11 @@ but also to its interactions with existing and future code.*

*If you answered more than a 2, explain what is complex about the PR,
and what other components it interacts with in potentially concerning ways.*

# Testing

*Describe any testing you've done, and any testing you'd like your reviewers to do,
so that you're confident that all the changes work as expected!*

- [x] *Write a test you've completed here.*
- [ ] *Write a test you want a reviewer to do here, so they can check it off when they're satisfied.*
4 changes: 2 additions & 2 deletions .github/workflows/benchmarks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ on:
push:
branches:
- master
- jgilles/fix-callgrind
- jgilles/fix-callgrind-again

workflow_dispatch:
inputs:
Expand Down Expand Up @@ -170,7 +170,7 @@ jobs:
runs-on: ubuntu-latest
timeout-minutes: 20 # on a successful run, runs in 8 minutes
container:
image: rust:1.72
image: rust:1.78
options: --privileged
# filter for a comment containing 'benchmarks please'
if: ${{ github.event_name != 'issue_comment' || (github.event.issue.pull_request && contains(github.event.comment.body, 'benchmarks please')) }}
Expand Down
133 changes: 133 additions & 0 deletions .github/workflows/bottest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,133 @@
on:
push:
branches:
- jgilles/bottest3
workflow_dispatch:
inputs:
pr_number:
description: 'Pull Request Number'
required: false
default: ''
issue_comment:
types: [created]

name: Automated bot test

env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_REPO: ${{ github.repository }}

jobs:
autobottest:
name: run bot test (30 bots)
runs-on: bots-runner
permissions: write-all
# filter for a comment containing 'benchmarks please'
if: ${{ github.event_name != 'issue_comment' || (github.event.issue.pull_request && contains(github.event.comment.body, 'bots please')) }}
env:
PR_NUMBER: ${{ github.event.inputs.pr_number || github.event.issue.number || null }}
steps:
- name: Check membership
if: ${{ github.event_name == 'issue_comment' }}
env:
CONTRIB_ORG: clockworklabs
COMMENT_AUTHOR: ${{ github.event.comment.user.login }}
ORG_READ_TOKEN: ${{ secrets.ORG_READ_TOKEN }}
run: |
curl -OL https://github.com/cli/cli/releases/download/v2.37.0/gh_2.37.0_linux_amd64.deb && sudo dpkg -i gh_2.37.0_linux_amd64.deb
if [[ $(GH_TOKEN=$ORG_READ_TOKEN gh api --paginate /orgs/{owner}/members --jq 'any(.login == env.COMMENT_AUTHOR)') != true ]]; then
gh pr comment $PR_NUMBER -b "Sorry, you don't have permission to run bot tests."
exit 1
fi

- name: Checkout sources
uses: actions/checkout@v4

- name: Post initial comment
run: |
if [[ $PR_NUMBER ]]; then
comment_parent=issues/$PR_NUMBER
comment_update=issues/comments
else
comment_parent=commits/$GITHUB_SHA
comment_update=comments
fi
comment_body="Bot test in progress..."
comment_id=$(gh api "/repos/{owner}/{repo}/$comment_parent/comments" -f body="$comment_body" --jq .id)
echo "COMMENT_UPDATE_URL=/repos/{owner}/{repo}/$comment_update/$comment_id" >>$GITHUB_ENV

- name: find PR branch
if: ${{ env.PR_NUMBER }}
run: echo "PR_REF=$(gh pr view $PR_NUMBER --json headRefName --jq .headRefName)" >>"$GITHUB_ENV"

- name: Checkout sources
uses: actions/checkout@v4
with:
ref: ${{ env.PR_REF || github.ref }}
fetch-depth: 1

- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
components: clippy
toolchain: stable
target: wasm32-unknown-unknown
override: true

- name: Build the bots
run: |
git apply .github/workflows/bottest_tracing_fix.patch
cargo build --release --bin spacetime

- name: Run bot test script
run: |
echo "We're on a bots runner, so expecting to find the BitCraftBots repo set up in the expected location"
echo "Let's hope the bots runner is up to date!!!"
SPACETIME_BIN="$PWD/target/release/spacetime"
cd ~/BitCraftBots
# using 'exec' allows the process to receive graceful termination signals (note: actions is bad)
exec python3 -m scripts.bottest "$SPACETIME_BIN"

- name: Archive results
run: |
RESULTS_NAME="pr-$PR_NUMBER-$GITHUB_SHA"
mkdir -p bottest-results
cp ~/BitCraftBots/results.zip bottest-results/$RESULTS_NAME.zip

- name: Upload bot test results to DO spaces
uses: clockworklabs/s3-upload-action@master
with:
aws_key_id: ${{ secrets.AWS_KEY_ID }}
aws_secret_access_key: ${{ secrets.AWS_SECRET_ACCESS_KEY}}
aws_bucket: "spacetimedb-private-bottest-results"
source_dir: bottest-results
endpoint: https://nyc3.digitaloceanspaces.com
destination_dir: bottests

- name: Post comment
run: |
RESULTS_NAME="pr-$PR_NUMBER-$GITHUB_SHA"
BODY="<details><summary>Bot test results</summary>

Test results are stored on DO Spaces [here](https://cloud.digitalocean.com/spaces/spacetimedb-private-bottest-results?path=bottests%2F). You'll need to log in
(we keep these secret).

The results of this test are named $RESULTS_NAME.zip.

</details>"

gh api "$COMMENT_UPDATE_URL" -X PATCH -f body="$BODY"

- name: Post failure comment
if: ${{ failure() && env.COMMENT_UPDATE_URL }}
run: |
BODY="Bot test failed. Please check [the workflow run](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) for details."
gh api "$COMMENT_UPDATE_URL" -X PATCH -f body="$BODY"

- name: Clean up
if: always()
run: |
rm -fr /stdb/*
rm -fr bottest-results/
rm -fr crates/bench/bottest/
13 changes: 13 additions & 0 deletions .github/workflows/bottest_tracing_fix.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/Cargo.toml b/Cargo.toml
index ec9ad430..8bd746d6 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -218,7 +218,7 @@ tokio-tungstenite = { version = "0.21", features = ["native-tls"] }
tokio-util = { version = "0.7.4", features = ["time"] }
toml = "0.8"
tower-http = { version = "0.5", features = ["cors"] }
-tracing = { version = "0.1.37", features = ["release_max_level_off"] }
+tracing = { version = "0.1.37" } #, features = ["release_max_level_off"] }
tracing-appender = "0.2.2"
tracing-core = "0.1.31"
tracing-flame = "0.2.0"
20 changes: 20 additions & 0 deletions .github/workflows/check-pr-base.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Git tree checks

on:
pull_request:
types: [opened, edited]
merge_group:
permissions: read-all

jobs:
check_base_ref:
name: Based on `master`
runs-on: ubuntu-latest
steps:
- id: not_based_on_master
if: |
github.event_name == 'pull_request' &&
github.event.pull_request.base.ref != 'master'
run: |
echo "This PR is not based on master. Please wait until the base PR merges."
exit 1
124 changes: 114 additions & 10 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,12 @@ on:
branches:
- master
merge_group:
workflow_dispatch:
inputs:
pr_number:
description: 'Pull Request Number'
required: false
default: ''

name: CI

Expand All @@ -12,17 +18,26 @@ jobs:
name: Smoketests
runs-on: spacetimedb-runner
steps:
- name: Find Git ref
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_NUMBER="${{ github.event.inputs.pr_number || null }}"
if test -n "${PR_NUMBER}"; then
GIT_REF="$( gh pr view --repo clockworklabs/SpacetimeDB $PR_NUMBER --json headRefName --jq .headRefName )"
else
GIT_REF="${{ github.ref }}"
fi
echo "GIT_REF=${GIT_REF}" >>"$GITHUB_ENV"
- name: Checkout sources
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
ref: ${{ env.GIT_REF }}
- uses: dsherret/rust-toolchain-file@v1
- name: Start containers
run: docker compose up -d
- name: Run smoketests
run: test/run-smoke-tests.sh --parallel -x bitcraftmini-pretest zz_docker-restart-module zz_docker-restart-repeating-reducer zz_docker-restart-sql
# These cannot run in parallel, even though the script tries to handle it
# TODO: Fix flaky tests https://github.com/clockworklabs/SpacetimeDB/issues/630
# - name: Run restarting smoketests
# run: test/run-smoke-tests.sh zz_docker-restart-module zz_docker-restart-repeating-reducer zz_docker-restart-sql
run: python -m smoketests --docker
- name: Stop containers
if: always()
run: docker compose down
Expand All @@ -31,8 +46,22 @@ jobs:
name: Test Suite
runs-on: spacetimedb-runner
steps:
- name: Find Git ref
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_NUMBER="${{ github.event.inputs.pr_number || null }}"
if test -n "${PR_NUMBER}"; then
GIT_REF="$( gh pr view --repo clockworklabs/SpacetimeDB $PR_NUMBER --json headRefName --jq .headRefName )"
else
GIT_REF="${{ github.ref }}"
fi
echo "GIT_REF=${GIT_REF}" >>"$GITHUB_ENV"

- name: Checkout sources
uses: actions/checkout@v3
uses: actions/checkout@v4
with:
ref: ${{ env.GIT_REF }}

- uses: dsherret/rust-toolchain-file@v1

Expand All @@ -46,7 +75,76 @@ jobs:
sudo chmod 777 /stdb

- name: Run cargo test
run: cargo test --all --features odb_rocksdb,odb_sled,metrics
run: cargo test --all

- name: C# bindings tests
working-directory: crates/bindings-csharp
run: dotnet test -warnaserror

sdk_test:
name: SDK Tests
runs-on: spacetimedb-runner
steps:
- name: Find Git ref
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
PR_NUMBER="${{ github.event.inputs.pr_number || null }}"
if test -n "${PR_NUMBER}"; then
GIT_REF="$( gh pr view --repo clockworklabs/SpacetimeDB $PR_NUMBER --json headRefName --jq .headRefName )"
else
GIT_REF="${{ github.ref }}"
fi
echo "GIT_REF=${GIT_REF}" >>"$GITHUB_ENV"

- name: Checkout sources
uses: actions/checkout@v4
with:
ref: ${{ env.GIT_REF }}

- uses: dsherret/rust-toolchain-file@v1

- uses: actions/setup-dotnet@v3
with:
dotnet-version: "8.x"

- name: Create /stdb dir
run: |
sudo mkdir /stdb
sudo chmod 777 /stdb
- name: Checkout C# SDK
uses: actions/checkout@v4
with:
repository: clockworklabs/spacetimedb-csharp-sdk
path: spacetimedb-csharp-sdk

- name: C# SDK tests
run: |
( cd crates/bindings-csharp/BSATN.Runtime && dotnet pack )
cd spacetimedb-csharp-sdk

# Write out the nuget config file to `nuget.config`. This causes the spacetimedb-csharp-sdk repository
# to be aware of the local versions of the `bindings-csharp` packages in SpacetimeDB, and use them if
# available. Otherwise, `spacetimedb-csharp-sdk` will use the NuGet versions of the packages.
# This means that (if version numbers match) we will test the local versions of the C# packages, even
# if they're not pushed to NuGet.
# See https://learn.microsoft.com/en-us/nuget/reference/nuget-config-file for more info on the config file,
# and https://tldp.org/LDP/abs/html/here-docs.html for more info on this bash feature.
cat >nuget.config <<EOF
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
<!-- Local NuGet repositories -->
<add key="Local SpacetimeDB.BSATN.Runtime" value="../crates/bindings-csharp/BSATN.Runtime/bin/Release" />
<!-- Official NuGet.org server -->
<add key="NuGet.org" value="https://api.nuget.org/v3/index.json" />
</packageSources>
</configuration>
EOF

# clear package caches, so we get fresh ones even if version numbers haven't changed
dotnet nuget locals all --clear
dotnet test

lints:
name: Lints
Expand All @@ -62,7 +160,13 @@ jobs:
run: cargo fmt --all -- --check

- name: Run cargo clippy
run: cargo clippy --all --tests --benches --features odb_rocksdb,odb_sled,metrics -- -D warnings
run: cargo clippy --all --tests --benches -- -D warnings

- name: Run C# formatting check
working-directory: crates/bindings-csharp
run: |
dotnet tool restore
dotnet csharpier --check .

wasm_bindings:
name: Build and test wasm bindings
Expand All @@ -74,7 +178,7 @@ jobs:
- run: echo ::add-matcher::.github/workflows/rust_matcher.json

- name: Build rust-wasm-test
run: cargo run -p spacetimedb-cli -- build modules/rust-wasm-test
run: cargo run -p spacetimedb-cli -- build --project-path modules/rust-wasm-test

- name: Run bindgen tests
run: cargo test -p spacetimedb-cli
Loading