Commit graph

71 commits

Author SHA1 Message Date
Nikita Sivukhin
16dd83441b fix python driver 2025-12-10 18:23:44 +04:00
Nikita Sivukhin
15fdd68892 format 2025-12-09 14:58:44 +04:00
Nikita Sivukhin
f513f66f20 cargo clippy --fix 2025-12-09 14:20:32 +04:00
Nikita Sivukhin
a9cc86954b fix python bindings 2025-12-09 14:12:18 +04:00
Nikita Sivukhin
dca6d0e05c fix bindings 2025-12-09 13:14:25 +04:00
Nikita Sivukhin
420037b82c use sdk-kit version in the pythod driver (just for consistency) 2025-12-04 23:27:35 +04:00
Nikita Sivukhin
6e30a3ce90 cargo fmt 2025-12-02 18:18:14 +04:00
Nikita Sivukhin
201f3a55f6 fix clippy 2025-12-02 18:16:57 +04:00
Nikita Sivukhin
ae603000e1 implement simple turso-sync bindings for python 2025-12-02 17:18:46 +04:00
Nikita Sivukhin
8df7f7e416 adjust python bindings 2025-12-02 16:03:06 +04:00
Nikita Sivukhin
52f492b93d slightly adjust database sdk-kit 2025-12-01 22:55:15 +04:00
Nikita Sivukhin
6d817530e2 cargo fmt 2025-11-28 03:24:04 +04:00
Nikita Sivukhin
a5b0dc0980 clippy 2025-11-28 03:21:47 +04:00
Nikita Sivukhin
85985cb64a add comment to the python bindings 2025-11-28 01:35:58 +04:00
Nikita Sivukhin
0c05cd3ca7 rewrite python bindings to be almost direct translation of sdk-kit 2025-11-27 17:53:31 +04:00
Nikita Sivukhin
78705493d8 use sdk-kit in python bindings 2025-11-27 14:12:08 +04:00
RS2007
60cbc6d8ea migrating from_uri to database opts 2025-11-02 16:28:22 +05:30
Pekka Enberg
913b7ac600 core: Disable autovacuum by default
People have discovered various bugs in autovacuum so let's disable it by
default for now.
2025-11-02 12:09:21 +02:00
Nikita Sivukhin
299533b7b6 hide custom modules syntax behind --experimental-custom-modules flag 2025-10-27 12:29:05 +04:00
Avinash Sajjanshetty
c8111f9555 Put encryption behind an opt in (runtime) flag 2025-09-30 18:29:18 +05:30
Diego Reis
7a56c93b81 Makes clippy happy 2025-09-25 10:42:14 -03:00
Pekka Enberg
12cf4d2e72 core: Make strict schema support experimental
It's not tested properly so let's mark it as experimental for now.

Fixes #2775
2025-09-02 16:40:02 +03:00
Mikaël Francoeur
2ee0132afe
rename functions 2025-08-15 17:08:53 -04:00
Nikita Sivukhin
857f9147f6 enable indices in the python SDK 2025-08-13 16:10:27 +04:00
Glauber Costa
145d6eede7 Implement very basic views using DBSP
This is just the bare minimum that I needed to convince myself that this
approach will work. The only views that we support are slices of the
main table: no aggregations, no joins, no projections.

drop view is implemented.
view population is implemented.
deletes, inserts and updates are implemented.

much like indexes before, a flag must be passed to enable views.
2025-08-10 23:34:04 -05:00
Jussi Saurio
86b1232268 chore: enable indexes by default 2025-08-01 15:44:56 +03:00
Pekka Enberg
993079e39d bindings/python: Add "experimental_indexes" parameter to connect() 2025-07-21 12:49:38 +03:00
Jussi Saurio
a48b6d049a Another post-rebase clippy round with 1.88.0 2025-07-12 19:10:56 +03:00
Pekka Enberg
5216e67d53 bindings/python: Start transaction implicitly in execute()
We need to start transaction implicitly in execute() for DML statements
to make sure first transaction is actually started.

Fixes #2002
2025-07-09 10:59:52 +03:00
Pere Diaz Bou
91107d364a only close connection in case of reference count is 1
Due to how `execute` is implemented, it returns a `Connection` clone
which internally shares a turso_core::Connection with every other
Connection. Since `execute` returns `Connection` and immediatly it is
dropped, it will close connection, checkpoint and leave database in
weird state.
2025-07-08 15:19:20 +02:00
pedrocarlo
711b1ef114 make all run_once be run under statement or connection so that rollback is called 2025-07-07 11:51:25 -03:00
Pekka Enberg
9303244f9d bindings/python: Explicit transaction control support 2025-07-03 16:50:21 +03:00
Pekka Enberg
603e57aff8 bindings/python: Fix ROLLBACK 2025-07-03 16:36:18 +03:00
PThorpe92
bbee10ba2c
Add mvcc and index config to connection open api 2025-06-30 22:04:56 -04:00
PThorpe92
c2670dbd67
Use connection::from_uri method in Python bindings 2025-06-30 22:03:51 -04:00
Pekka Enberg
53ba3ff926 Rename limbo_core crate to turso_core 2025-06-29 09:59:17 +03:00
Pekka Enberg
a5b539f1bf bindings/python: Rename package to pyturso 2025-06-27 11:27:08 +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
2123858770 bindings/python: Add Connection.rollback() 2025-06-25 20:02:09 +03:00
Nils Koch
2827b86917
chore: fix clippy warnings 2025-06-23 19:52:13 +01: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
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
Pere Diaz Bou
ee55116ca6 return row as reference to registers 2025-03-29 22:04:08 +01:00
Pere Diaz Bou
5b7fcd27bd make column reuse blob/text fields 2025-03-29 22:02:49 +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
Diego Reis
ab8187f4e6 ext/python: Gracefully close connection by closing it at Drop 2025-03-24 12:21:15 -03:00
Diego Reis
4ca5b11bed ext/python: Add support for Context Manager 2025-03-24 12:20:13 -03:00
Diego Reis
16b9325830 ext/python: Basic support for placeholding insert 2025-03-20 17:10:12 -03:00
Diego Reis
2481d73d70 ext/python: Partially implements commit()
It was based on https://docs.python.org/3/library/sqlite3.html but some more work is needed specially in LEGACY_TRANSACTION_CONTROL and isolation levels.

See: https://docs.python.org/3/library/sqlite3.html#sqlite3.Connection.autocommit
2025-03-20 17:09:55 -03:00