pedrocarlo
56d87cb916
move disable behavior to connection instead of checkpoint
2025-07-03 12:05:53 -03:00
pedrocarlo
3861584edc
add test for wal checkpointing correctly
2025-07-03 12:04:17 -03:00
pedrocarlo
44b8275b26
add test + implement sqlite3_column_int64 for test
2025-07-03 12:04:17 -03:00
pedrocarlo
db005c81a0
add option to disable wal checkpoint
2025-07-03 12:04:17 -03:00
Pekka Enberg
53ba3ff926
Rename limbo_core
crate to turso_core
2025-06-29 09:59:17 +03:00
Pekka Enberg
2fc5c0ce5c
Switch to runtime flag for enabling indexes
...
Makes it easier to test the feature:
```
$ cargo run -- --experimental-indexes
Limbo v0.0.22
Enter ".help" for usage hints.
Connected to a transient in-memory database.
Use ".open FILENAME" to reopen on a persistent database
limbo> CREATE TABLE t(x);
limbo> CREATE INDEX t_idx ON t(x);
limbo> DROP INDEX t_idx;
```
2025-06-26 10:07:28 +03:00
Pekka Enberg
5c35810f78
sqlite3: Make Clippy happy
2025-06-16 11:07:39 +03:00
Pekka Enberg
5b47c9932d
sqlite3: Make sqlite3
thread safe with a mutex
...
Make the sqlite3 object thread-safe with a mutex, like SQLite does.
2025-06-16 11:03:21 +03:00
Pekka Enberg
5fb50245ed
sqlite3: Clean up sqlite3_wal_checkpoint() function
2025-06-16 11:02:44 +03:00
Pekka Enberg
50fdf7105d
sqlite3: Clean up sqlite3_extended_errcode() function
2025-06-16 11:02:44 +03:00
Pekka Enberg
6901b7bcd6
sqlite3: Clean up sqlite3_errmsg() function
2025-06-16 11:02:44 +03:00
Pekka Enberg
0830578ec5
sqlite3: Clean up sqlite3_errcode() function
2025-06-16 11:02:44 +03:00
Pekka Enberg
5477d0a4f5
sqlite3: Clean up sqlite3_safety_check_sick_or_ok() function
...
Underscore in parameter or variable name indicates it's not used. Also,
drop useless `crate` qualifier from constants.
2025-06-16 11:02:44 +03:00
Pekka Enberg
0b0f712575
sqlite3: Move sqlite3_safety_check_sick_or_ok() to lib.rs
...
It's pointless to have a module for just one function...
2025-06-16 11:02:43 +03:00
Pekka Enberg
90c1e3fc06
Switch Connection to use Arc instead of Rc
...
Connection needs to be Arc so that bindings can wrap it with `Mutex` for
multi-threading.
2025-06-16 10:43:19 +03:00
Jussi Saurio
e59c1ac985
tests/compat: use tempfiles for all empty dbs the tests open
2025-05-29 11:01:37 +03:00
Pekka Enberg
ac97ac36a6
Fix broken build in sqlite3 tests
...
Thanks for the heads up Pedro!
2025-05-27 18:44:41 +03:00
Pekka Enberg
99926c5f99
sqlite3/tests: Clippy is not happy
2025-05-27 18:16:54 +03:00
Pekka Enberg
edfa7402f0
sqlite3/test: Use tempfile in read frame test case
...
...make test runs idempotent, as suggested by Jussi.
2025-05-27 16:45:02 +03:00
Pekka Enberg
3250560eb8
sqlite3: Add libsql_wal_get_frame() API
2025-05-27 13:47:40 +03:00
Pekka Enberg
9f5904d4df
cargo fmt
2025-05-22 13:02:30 +03:00
Pekka Enberg
7d471889eb
sqlite3: Switch to tracing logger
...
...we now actually see logging from core too.
2025-05-22 12:37:09 +03:00
PThorpe92
45de41626c
Adjust sqlite3 compat tests to use temp cloned database so further tests dont break
2025-05-17 16:11:59 -04:00
Pekka Enberg
524a523036
sqlite3: Add libsql_wal_frame_count() API
2025-05-15 11:43:44 +03:00
Pekka Enberg
78eb901940
sqlite3: Fix sqlite3_step() when I/O is submitted
2025-05-15 11:43:44 +03:00
Pekka Enberg
4553adf317
Merge 'Rename OwnedValue -> Value' from Pekka Enberg
...
We have not had enough merge conflicts for a while so let's do a tree-
wide rename.
Closes #1488
2025-05-15 10:31:36 +03:00
Pekka Enberg
b07738e54b
sqlite3: Update sqlite3.h
with cbindgen
...
...people have been manually tweaking the header, but it's out of date.
Let's just use "cbindgen", which is the sensible thing to do.
2025-05-15 10:07:54 +03:00
Pekka Enberg
e3f71259d8
Rename OwnedValue -> Value
...
We have not had enough merge conflicts for a while so let's do a
tree-wide rename.
2025-05-15 09:59:46 +03:00
Pekka Enberg
12238870b7
sqlite3/tests: Make Clippy happy
...
There nothing more important to me personally than keeping the computer happy.
2025-05-15 09:38:41 +03:00
Pekka Enberg
dde897d172
sqlite3/tests: Remove test case from test_wal_checkpoint_v2
2025-05-15 09:30:42 +03:00
Pekka Enberg
de8d4dfe4f
sqlite3/tests: Remove test case from test_wal_checkpoint
...
Turns out SQLite SIGSEGVs on CI runs for this...
2025-05-15 09:15:47 +03:00
Pekka Enberg
cac464b49a
sqlite3: Switch error to trace-level logging
...
...it's pretty pointless to spam the logs for this.
2025-05-15 09:15:35 +03:00
Pekka Enberg
7458848a56
sqlite3/tests: Remove C-based compat tests
...
...they're now just duplicating the Rust ones.
2025-05-15 09:15:35 +03:00
Pekka Enberg
0e5234ee86
sqlite3/tests: Skip compat test on Windows
...
We have linking issues with the static libraries so skip them for now.
2025-05-15 09:15:35 +03:00
Pekka Enberg
358a40928f
sqlite3/tests: Make Clippy happy
2025-05-15 09:15:35 +03:00
Pekka Enberg
18dbf033d8
sqlite3/tests: Enable all test cases
2025-05-15 09:15:35 +03:00
Pekka Enberg
cf66dfcdaf
sqlite3/tests: Remove invalid test_open_misuse test case
...
You can pass NULL to `sqlite3_open()` and it will open a private,
temporary on-disk database. Therefore, drop the broken test.
2025-05-15 09:15:35 +03:00
Pekka Enberg
fde5484e93
sqlite3/tests: Relax test_libversion_number assertion
...
...make it less dependent on specific version of SQLite.
2025-05-15 09:15:35 +03:00
Pekka Enberg
41e9d7f9b8
sqlite3/tests: Run Rust-based test suite also with SQLite
...
You can now run the tests with SQLite with:
```
cargo test --test compat --features sqlite3
```
2025-05-15 09:15:35 +03:00
Pere Diaz Bou
ee55116ca6
return row as reference to registers
2025-03-29 22:04:08 +01:00
Pere Diaz Bou
bf37fd3314
wip
2025-03-29 22:02:49 +01:00
Pere Diaz Bou
9291f60722
Introduce Register
struct
...
OwnedValue has become a powerhouse of madness, mainly because I decided
to do it like that when I first introduced AggContext. I decided it was
enough and I introduced a `Register` struct that contains `OwnedValue`,
`Record` and `Aggregation`, this way we don't use `OwnedValue` for
everything make everyone's life harder.
This is the next step towards making ImmutableRecords the default
because I want to remove unnecessary allocations. Right now we clone
OwnedValues when we generate a record more than needed.
2025-03-27 17:53:02 +01:00
Pekka Enberg
7fc61b7b3d
sqlite3: Add trace logging to sqlite3_exec()
2025-03-17 16:17:18 +02:00
Pekka Enberg
7ae1da0f3c
Ignore some failing Rust SQLite test cases
...
...they fail on CI, but not locally so disable them until we got them sorted out.
2025-03-12 18:56:32 +02:00
Pere Diaz Bou
f7c8d4cc69
test_open_existing fix
2025-03-12 16:06:52 +01:00
Pere Diaz Bou
e65d76f51f
fmt
2025-03-12 16:06:29 +01:00
Pere Diaz Bou
40a78c32b6
fix sqlite3 lib db test path
2025-03-12 16:00:46 +01:00
Pekka Enberg
cb68b2ec1b
sqlite3: cargo fmt
2025-03-10 12:22:01 +02:00
karan
34876c4711
fixing erro code for sqlite open
...
Signed-off-by: karan <karanjanthe@gmail.com>
2025-03-08 09:52:43 +05:30
Pekka Enberg
96175cccf7
cli: Add --experimental-mvcc
option to enable MVCC
2025-03-06 10:16:42 +02:00