93 Commits

Author SHA1 Message Date
gigagrug
b7bdbefe8b Create README.md for Turso Database Python bindings
Added README.md for Turso Database Python bindings with installation instructions, features, and usage examples.
2025-11-13 20:19:50 -05: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
pedrocarlo
5b2cce946a do not reference workspace package by path 2025-10-13 21:07:15 -03: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
PThorpe92
ba1ed72ed8 Add tracing_release feature for benchmarks to compile tracing macros to noops 2025-09-10 09:56:12 -04: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
Pekka Enberg
b895381ae6 Revert "Merge 'Reachable assertions in Antithesis Python Test for better logging' from Pedro Muniz"
This reverts commit dbbc3f5190, reversing
changes made to 1cd5a49705. We're missing
some mandatory parameters, causing these to fail under Antithesis.
2025-07-08 17:51:12 +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
e9361c0eba add more logging to antithesis tests
format python tests
2025-07-07 19:11:55 -03: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
Pekka Enberg
df257d3048 Merge 'Turso, not Limbo, in pyproject.toml' from Simon Willison
https://pypi.org/project/pyturso/0.1.1/ is still showing the old name:
![CleanShot 2025-07-01 at 07 30 11@2x](https://github.com/user-
attachments/assets/a80441ec-507c-4ff7-a698-3cb88625c2cc)

Closes #1912
2025-07-02 19:33:05 +03:00
Simon Willison
a46818fda0 Turso, not Limbo, in pyproject.toml 2025-07-01 07:29:06 -07: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
9c1b7897ac Fix URLs to point to github.com/tursodatabase/turso 2025-06-30 11:23:53 +03: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
pedrocarlo
8b8f43334e remove python makefile as it is obsolete with UV 2025-06-20 15:59:03 -03:00
pedrocarlo
80ccca8827 ruff lint fix 2025-06-20 15:59:03 -03:00
pedrocarlo
50c8b2ca2e extract ruff lint rules to workspace 2025-06-20 15:59:03 -03:00
pedrocarlo
46135e43ce use uv in github actions 2025-06-20 15:59:03 -03:00
Pere Diaz Bou
4514bd5681 use integer primary key on test_in_memory_fetchone_select_all_users 2025-06-17 19:33:23 +02: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
dependabot[bot]
a56e6ebc7d build(deps): bump pyo3 from 0.24.0 to 0.24.1
Bumps [pyo3](https://github.com/pyo3/pyo3) from 0.24.0 to 0.24.1.
- [Release notes](https://github.com/pyo3/pyo3/releases)
- [Changelog](https://github.com/PyO3/pyo3/blob/v0.24.1/CHANGELOG.md)
- [Commits](https://github.com/pyo3/pyo3/compare/v0.24.0...v0.24.1)

---
updated-dependencies:
- dependency-name: pyo3
  dependency-version: 0.24.1
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
2025-04-11 07:01:07 +00: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
160d48d34e ext/python: Workaround to file permission error
To get more info see:
https://github.com/tursodatabase/limbo/actions/runs/14039536389/job/39312362848
2025-03-24 16:39:24 -03:00
Diego Reis
6edf3dd3b1 ext/python: Makes linter happy 2025-03-24 12:40:59 -03:00
Diego Reis
9a8970b6a8 ext/python: Update example 2025-03-24 12:21:30 -03: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
2ee934577f ext/python: Close connection after each test 2025-03-21 12:02:27 -03:00