| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
(#108621)
gh-108550: Fix sqlite3 CLI regression from gh-108551 (GH-108618)
(cherry picked from commit c8847841cc5629cbceead0c09dc6f537d7b92612)
Co-authored-by: Erlend E. Aasland <erlend@python.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
gh-108550: Speed up sqlite3 tests (GH-108551)
Refactor the CLI so we can easily invoke it and mock command-line
arguments. Adapt the CLI tests so we no longer have to launch a
separate process.
Disable the busy handler for all concurrency tests; we have full
control over the order of the SQLite C API calls, so we can safely
do this.
The sqlite3 test suite now completes ~8 times faster than before.
(cherry picked from commit 0e8b3fc718c8a1c4de558c553d9e05049c1dbec6)
Co-authored-by: Erlend E. Aasland <erlend@python.org>
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(#108340) (#108563)
* [3.12] gh-64662: Add virtual table support to sqlite3.Connection.iterdump (#108340)
(cherry picked from commit d0160c7c22c8dff0a61c49b5304244df6e36465e)
Co-authored-by: Aviv Palivoda <palaviv@gmail.com>
* The _quote_value helper is not part of 3.12; spell out the replacement
* With quotes
* Ok, let's use explicit quoting
---------
Co-authored-by: Aviv Palivoda <palaviv@gmail.com>
|
| |
|
|
|
|
| |
The prompt will still be incorrect in IDLE on Windows,
as IDLE uses CTRL-D for EOF on all platforms.
|
|
|
|
| |
Co-authored-by: Ezio Melotti <ezio.melotti@gmail.com>
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
|
|
|
| |
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
|
|
|
| |
Co-authored-by: CAM Gerlach <CAM.Gerlach@Gerlach.CAM>
|
|
|
|
|
| |
(#9621)
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
|
|
|
|
|
| |
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
Co-authored-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
|
|
|
|
|
|
|
|
|
|
| |
The following sqlite3 features were deprecated in 3.10, scheduled for
removal in 3.12:
- sqlite3.OptimizedUnicode (gh-23163)
- sqlite3.enable_shared_cache (gh-24008)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Signed-off-by: Erlend E. Aasland <erlend.aasland@protonmail.com>
|
|
|
| |
Co-authored-by: Jonathan <89750679+AHypnotoad@users.noreply.github.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* bpo-45677: Avoid addressing the reader as 'you' in sqlite3 docs
* Adjust wording
* Adjust wording again
* Typo
* Update Doc/library/sqlite3.rst
Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
* Address review: adjust wording
* Update Doc/library/sqlite3.rst
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* Update Lib/sqlite3/__init__.py
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* Update Doc/library/sqlite3.rst
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* Update Doc/library/sqlite3.rst
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* Update Lib/sqlite3/__init__.py
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* Update Doc/library/sqlite3.rst
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
* Apply Alex' suggestion, and apply 80 char limit to PR
* Minor adjustment
Co-authored-by: Jacob Walls <jacobtylerwalls@gmail.com>
Co-authored-by: Alex Waygood <Alex.Waygood@Gmail.com>
|
|
|
|
|
|
|
|
|
| |
Use the compile-time selected default SQLite threaded mode to set the
DB-API 2.0 attribute 'threadsafety'
Mappings:
- SQLITE_THREADSAFE=0 => threadsafety=0
- SQLITE_THREADSAFE=1 => threadsafety=3
- SQLITE_THREADSAFE=2 => threadsafety=1
|
|
|
| |
Automerge-Triggered-By: GH:brettcannon
|
| |
|
|
|
| |
Automerge-Triggered-By: GH:pablogsal
|
|
|
|
|
|
|
| |
(GH-28509)
* bpo-45041: Restore sqlite3 executescript behaviour for select queries
* Add regression test
|
|
|
|
|
| |
Fix typos in the Lib directory as identified by codespell.
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
|
|
|
|
|
|
| |
Modify managed_connect() helper to support in-memory databases. Use it
for the regression tests added in GH-27844.
Automerge-Triggered-By: GH:pablogsal
|
| |
|
|
|
|
|
| |
preceeding -> preceding
Co-authored-by: Łukasz Langa <lukasz@langa.pl>
|
|
|
|
|
| |
Use unittest discover instead of manually enumerating all
test modules and classes.
Also add support for filtering them by pattern.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
(GH-26202)
Co-authored-by: Luca Citi
Co-authored-by: Berker Peksag <berker.peksag@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
exceptions. (GH-27654)
* MemoryError is now raised instead of sqlite3.Warning when
memory is not enough for encoding a statement to UTF-8
in Connection.__call__() and Cursor.execute().
* UnicodEncodeError is now raised instead of sqlite3.Warning when
the statement contains surrogate characters
in Connection.__call__() and Cursor.execute().
* TypeError is now raised instead of ValueError for non-string
script argument in Cursor.executescript().
* ValueError is now raised for script containing the null
character instead of truncating it in Cursor.executescript().
* Correctly handle exceptions raised when getting boolean value
of the result of the progress handler.
* Add many tests covering different corner cases.
Co-authored-by: Erlend Egeberg Aasland <erlend.aasland@innova.no>
|
|
|
|
|
|
| |
MemoryError raised in user-defined functions will now preserve
its type. OverflowError will now be converted to DataError.
Previously both were converted to OperationalError.
|
|
|
|
| |
`sqlite3` UDF callbacks (GH-27588)
|
| |
|
| |
|
| |
|
| |
|
|
|
| |
Also adds a test to verify the (borrowed) exceptions in `sqlite3.Connection`.
|
|
|
|
|
|
|
| |
1. Rewrite ThreadTests with a _run_test() helper method that does the heavy lifting
2. Add test.support.threading_helper.reap_threads to _run_test()
3. Use _run_test() in all threading tests
4. Add test case for sqlite3.Connection.set_trace_callback
5. Add test case for sqlite3.Connection.create_collation
|
| |
|
|
|
|
| |
(GH-24421)
|
|
|
|
| |
objects (GH-26545)
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
The sqlite3 module now fully implements the GC protocol, so there's no
need for this workaround anymore.
- Add and use managed resource helper for connections using TESTFN
- Sort test imports
- Split open-tests into their own test case
Automerge-Triggered-By: GH:vstinner
|
|
|
|
|
|
|
|
|
| |
Try to harden connection close:
- add tests that exercise stuff against a closed database
- add wrapper for sqlite3_close_v2()
- check connection on __enter__
- explicitly free pending statements before close()
- sqlite3_close_v2() always returns SQLITE_OK
|
| |
|
| |
|
| |
|
|
|
|
| |
(GH-25228)
|
| |
|
|
|
| |
Regression introduced in 47feb1feb28631b6647699b7633109aa85340966.
|