Commit Graph

60 Commits

Author SHA1 Message Date
PThorpe92
ba1ed72ed8 Add tracing_release feature for benchmarks to compile tracing macros to noops 2025-09-10 09:56:12 -04:00
Pekka Enberg
1f6ba4f822 Merge 'Fix sim-schema command ' from Pedro Muniz
Create the directory to store the schema if it does not exists

Reviewed-by: Preston Thorpe <preston@turso.tech>

Closes #2882
2025-09-02 09:08:57 +03:00
Pekka Enberg
cfaba4ab10 Merge 'Implement libSQL's ALTER COLUMN extension' from Levy A.
Implement `ALTER COLUMN` as described here:
https://github.com/tursodatabase/libsql/blob/main/libsql-
sqlite3/doc/libsql_extensions.md#altering-columns
- [x] Add `ALTER COLUMN` to parser
- [x] Implement `Insn::AlterColumn`
- [x] Add tests

Closes #2814
2025-09-02 09:06:03 +03:00
pedrocarlo
72d697e0eb fix sim-schema command by creating directory if it not exists 2025-09-01 21:05:25 -03:00
pedrocarlo
961c0cd282 script to save JsonSchema for editor integration 2025-08-30 12:17:50 -03:00
Levy A.
293865c2d6 feat+fix: add tests and restrict altering some constraints 2025-08-30 03:43:31 -03:00
Jussi Saurio
6c7abc5caa Serialize compat tests to prevent file locking failures 2025-08-22 10:38:47 +03:00
PThorpe92
4fab57767b Add bench-sqlite script and makefile command for benchmarking an I/O backend against sqlite3 2025-08-18 15:11:29 -04:00
Glauber Costa
7e76970035 fix: Handle fresh INSERTs in materialized view incremental maintenance
The op_insert function was incorrectly trying to capture an "old record"
for fresh INSERT operations when a table had dependent materialized views.
This caused a "Cannot delete: no current row" error because the cursor
wasn't positioned on any row for new inserts.

The issue was introduced in commit f38333b3 which refactored the state
machine for incremental view handling but didn't properly distinguish
between:
- Fresh INSERT operations (no old record exists)
- UPDATE operations without rowid change (old record should be captured)
- UPDATE operations with rowid change (already handled by DELETE)

This fix checks if cursor.rowid() returns a value before attempting to
capture the old record. If no row exists (fresh INSERT), we correctly
set old_record to None instead of erroring out.

I am also including tests to make sure this doesn't break. The reason I
didn't include tests earlier is that I didn't know it was possible to
run the tests under a flag. But in here, I am just adding the flag to
the execution script.
2025-08-13 06:41:14 -05:00
Pekka Enberg
4aea9372bd Rename liblimbo_sqlite3 to libturso_sqlite3 2025-08-02 11:24:40 +03:00
PThorpe92
84900c4da2 Check repository scope in merge pr script 2025-07-31 11:39:57 -04:00
PThorpe92
ca383a3b88 Fix merge-py.py script to use github CLI and add makefile command 2025-07-31 10:20:17 -04:00
PThorpe92
9cba19309e Add .dockerignore and Makefile commands to support docker 2025-07-31 00:00:44 -04:00
Diego Reis
98bec9868b Remove wasm binding
With napi v3 we can compile our javascript binding to wasm, which can
reduce a lot of maintenance overhead and complexity
2025-07-28 14:48:51 -03:00
Nils Koch
bab8001a9c use wasm32-wasip1 target instead of wasm32-wasi 2025-07-19 13:16:46 +01:00
Pekka Enberg
458dd815ac testing: Add MVCC test suite 2025-07-17 16:23:31 +03:00
Mikaël Francoeur
a57c4c1b6e enforce tcl 8.6+ 2025-07-09 11:30:38 -04:00
pedrocarlo
90878e12b1 remove cargo-c from CI + let makefile decide what is needed to uv sync for testing 2025-07-07 15:34:29 -03:00
pedrocarlo
81f80edd4a remove experimental_flag from script + remove -q flag default flag from TestTursoShell 2025-07-07 15:34:03 -03:00
pedrocarlo
89a81f9926 remove logging in test 2025-07-07 11:50:21 -03:00
Pekka Enberg
37566d29cc cli: Remove extra binary
The `cargo-dist` tool attempts to find it but because we never build it,
packaging fails. Remove the extra binary. Probably better to work
towards making experimental indexes a runtime flag instead.
2025-06-19 09:41:01 +03:00
Pere Diaz Bou
878e39eee0 skip python write tests without indexes 2025-06-17 19:33:23 +02:00
Pere Diaz Bou
9ae4563bcd index_experimental flag to enable index usages
Currently indexes are the bulk of the problem with `UPDATE` and
`DELETE`, while we work on fixing those it makes sense to disable
indexing since they are not stable. We want to try to make everything
else stable before we continue with indexing.
2025-06-17 19:33:23 +02:00
pedrocarlo
66f82e47f5 tpc-h with criterion and nyrkio 2025-05-23 01:32:16 -03:00
pedrocarlo
a818b6924c Removed repeated binary expression translation. Adjusted the set_collation to capture additional context of whether it was set by a Collate expression or not. Added some tests to prove those modifications were necessary. 2025-05-19 15:22:14 -03:00
PThorpe92
6d70e6d048 Add reset db to Makefile to create clean testing db between tests that perform writes 2025-05-17 16:23:17 -04:00
Pekka Enberg
0db542171f Makefile: Update test-sqlite3 target to run Rust tests
The API compat test suite is now all in Rust.
2025-05-15 09:15:35 +03:00
pedrocarlo
2e147b20a8 Adjustments and explicitely just emitting NoConflict on unique indexes 2025-04-24 13:13:39 -03:00
PThorpe92
2e33ce6896 Add release build to bench vfs in makefile to ensure there is an exec target 2025-04-21 12:31:38 -04:00
PThorpe92
2037fbeba5 Add bench-vfs command to makefile 2025-04-21 12:22:40 -04:00
pedrocarlo
bd5531987e adjusting memory test to use UV 2025-04-15 12:51:43 -03:00
pedrocarlo
bdef83dc1c update test 2025-04-15 12:45:46 -03:00
pedrocarlo
58e091cb23 setup uv for limbo 2025-04-15 12:45:46 -03:00
pedrocarlo
862783aec7 forgot to add to test command in makefile 2025-04-15 12:45:46 -03:00
pedrocarlo
46eaa52400 write tests for file backed db 2025-04-15 12:45:45 -03:00
pedrocarlo
8f202e8015 separate memory tests to track large blob insertions 2025-04-01 19:42:44 -03:00
Pekka Enberg
7832ae22df Enable pretty mode in shell by default
Fixes #929
2025-03-22 08:10:26 +02:00
PThorpe92
6c98cf4d82 Clean up extension python tests to use convenience CLI-test class 2025-02-25 20:36:35 -05:00
Jussi Saurio
e8c0717f5b Add modified clickbench script to repo + CI 2025-02-15 11:48:06 +02:00
CK-7vn
5f02521d08 cleanup shell tests and cli 2025-02-13 00:49:12 -05:00
pedrocarlo
eb40505c31 some tests in sqlite rely on commands not implemented in limbo yet 2025-02-06 23:36:02 -03:00
pedrocarlo
9acba9c140 added tests 2025-02-01 16:13:37 -03:00
Pekka Enberg
b9c89e79c2 testing: Add few TCL tests for vector extensions 2025-01-28 14:24:09 +02:00
PThorpe92
cc63aac305 Fix tests to account for built-in extensions 2025-01-21 09:32:44 -05:00
PThorpe92
9c208dc866 Add tests for first extension 2025-01-14 07:27:35 -05:00
Daniel Kaluza
34690e3b63 Remove dependency on system libsqlite headers from compatibility tests 2025-01-03 11:19:21 +01:00
PThorpe92
1833dcb618 Shrink shell help msg and replace hardcoded path for shell tests 2024-12-16 20:14:04 -05:00
PThorpe92
7ca0abc61d Replace tcl with python tests and add to makefile 2024-12-15 21:40:42 -05:00
PThorpe92
fb70be752e Add first tests for shell specific options and behavior 2024-12-15 18:23:40 -05:00
Luca Barbato
eacbba2c07 Minimal cargo-c support 2024-12-14 15:19:50 +01:00