Commit Graph

97 Commits

Author SHA1 Message Date
Berker Peksag e0b70cd8a9 Issue #16864: Cursor.lastrowid now supports REPLACE statement
Initial patch by Alex LordThorsen.
2016-06-14 15:25:36 +03:00
Berker Peksag f85bce74db Mark tests as skipped when a SQLite version is not supported 2016-06-14 14:19:02 +03:00
Berker Peksag 2b50899a28 Remove empty setUp and tearDown methods from sqlite3 tests
They are not used as base classes by another tests so they
can safely be removed.
2016-06-14 13:25:11 +03:00
Berker Peksag 48b5c98e6e Replace more boilerplate code with modern unittest features in sqlite3 tests 2016-06-14 00:42:50 +03:00
Berker Peksag 1003b34c71 Modernize sqlite3 tests
Update current tests that use old pattern with assertRaises
to make them more maintainable.
2016-06-12 22:34:49 +03:00
Berker Peksag 7bea2347c7 Issue #27190: Raise NotSupportedError if sqlite3 is older than 3.3.1
Patch by Dave Sawyer.
2016-06-12 14:09:51 +03:00
Berker Peksag c415440faa Issue #27188: Fix various sqlite3 documentation errors
* Connection.execute* methods don't create intermediate cursor objects
* Fix description of seq_of_parameters parameter
* Clarify that Warning is sqlite3.Warning
* sql_script parameter of Cursor.executescript() doesn't accept bytes
* Add missing tests
* Fix various markup errors

Initial patch by Dave Sawyer.
2016-06-12 13:41:47 +03:00
Serhiy Storchaka 6a7b3a77b4 Issue #26778: Fixed "a/an/and" typos in code comment and documentation. 2016-04-17 08:32:47 +03:00
Berker Peksag fa0f62d6ab Issue #23758: Improve num_params docs of create_{function,aggregate} functions
If you pass -1, the callable can take any number of arguments.

Added tests to verify the behavior.

Initial patch by Cédric Krier.
2016-03-27 22:39:14 +03:00
Serhiy Storchaka e79ec70801 Issue #24257: Fixed incorrect uses of PyObject_IsInstance().
Fixed segmentation fault in sqlite3.Row constructor with faked cursor type.
Fixed system error in the comparison of faked types.SimpleNamespace.
2015-05-22 11:13:20 +03:00
Serhiy Storchaka 08d230a540 Issue #24257: Fixed incorrect uses of PyObject_IsInstance().
Fixed segmentation fault in sqlite3.Row constructor with faked cursor type.
Fixed system error in the comparison of faked types.SimpleNamespace.
2015-05-22 11:02:49 +03:00
Serhiy Storchaka 72e731cc03 Issue #13583: sqlite3.Row now supports slice indexing.
Tests by Jessica McKellar.
2015-03-31 13:33:11 +03:00
Serhiy Storchaka a60c2fe480 Issue #23641: Cleaned out legacy dunder names from tests and docs.
Fixed 2 to 3 porting bug in pynche.ColorDB.
2015-03-12 21:56:08 +02:00
Serhiy Storchaka 42d67af87f Issue #21147: sqlite3 now raises an exception if the request contains a null
character instead of truncate it.  Based on patch by Victor Stinner.
2014-09-11 13:29:05 +03:00
Serhiy Storchaka 47a981337a Issue #10203: sqlite3.Row now truly supports sequence protocol. In particulr
it supports reverse() and negative indices.  Original patch by Claudiu Popa.
2014-05-28 12:58:34 +03:00
Benjamin Peterson a6d018ad6e merge 3.3 (#20901) 2014-03-12 21:52:19 -05:00
Benjamin Peterson 966f2fca5f weaken callback count inequality (closes #20901) 2014-03-12 21:51:52 -05:00
Benjamin Peterson 5ef48d9c79 merge 3.3 (#20080) 2014-02-15 13:20:28 -05:00
Benjamin Peterson 29352c436c add missing test assertion (closes #20080)
Patch by Vajrasky Kok.
2014-02-15 13:19:59 -05:00
Victor Stinner 08263f10f8 (Merge 3.3) Issue #20026: Fix the sqlite module to handle correctly invalid
isolation level (wrong type).
2013-12-19 16:39:00 +01:00
Victor Stinner cb1f74ec40 Issue #20026: Fix the sqlite module to handle correctly invalid isolation level
(wrong type).
2013-12-19 16:38:03 +01:00
Serhiy Storchaka d4b75bf63e Issue #19601: Use specific asserts in sqlite3 tests. 2013-11-17 00:40:01 +02:00
Serhiy Storchaka 78ee078405 Issue #19601: Use specific asserts in sqlite3 tests. 2013-11-17 00:39:12 +02:00
Ezio Melotti e0c69161bc #18741: merge with 3.3. 2013-08-17 16:13:22 +03:00
Ezio Melotti b5bc353b88 #18741: fix more typos. Patch by Févry Thibault. 2013-08-17 16:11:40 +03:00
Brett Cannon cd171c8e92 Issue #18200: Back out usage of ModuleNotFoundError (8d28d44f3a9a) 2013-07-04 17:43:24 -04:00
Brett Cannon 0a140668fa Issue #18200: Update the stdlib (except tests) to use
ModuleNotFoundError.
2013-06-13 20:57:26 -04:00
Petri Lehtinen e55aa69efc Issue #14720: Enhance sqlite3 microsecond conversion, document its behavior 2013-02-26 21:46:12 +02:00
Petri Lehtinen 6401ad66a7 Issue #14720: Enhance sqlite3 microsecond conversion, document its behavior 2013-02-26 21:45:09 +02:00
Petri Lehtinen 5f79409889 Issue #14720: Enhance sqlite3 microsecond conversion, document its behavior 2013-02-26 21:38:17 +02:00
Petri Lehtinen e460f26b25 Issue #14720: sqlite3: Convert datetime microseconds correctly 2013-02-23 19:10:29 +01:00
Petri Lehtinen f484efdb60 Issue #14720: sqlite3: Convert datetime microseconds correctly 2013-02-23 19:09:45 +01:00
Petri Lehtinen 8b945148e3 Issue #14720: sqlite3: Convert datetime microseconds correctly
Patch by Lowe Thiderman
2013-02-23 19:05:56 +01:00
Antoine Pitrou 902fc8b5a0 Issue #13773: sqlite3.connect() gets a new `uri` parameter to pass the filename as a URI, allowing to pass custom options. 2013-02-10 00:02:44 +01:00
Serhiy Storchaka 2efdc90b0f Issue #17073: Fix some integer overflows in sqlite3 module. 2013-02-07 17:03:46 +02:00
Serhiy Storchaka 3cf96ac248 Issue #17073: Fix some integer overflows in sqlite3 module. 2013-02-07 17:01:47 +02:00
R David Murray d394455aae merge #13934: document sqlite version strings, use correct one in test. 2013-01-10 20:19:35 -05:00
R David Murray 3f7beb99dd #13934: document sqlite version strings, use correct one in test. 2013-01-10 20:18:21 -05:00
R David Murray 7bd04867e5 merge #15545: fix sqlite3.iterdump regression on unsortable row_factory objects.
The fix for issue 9750 introduced a regression by sorting the row objects
returned by fetchall.  But if a row_factory such as sqlite3.Row is used, the
rows may not be sortable (in Python3), which leads to an exception.  The
sorting is still a nice idea, so the patch moves the sort into the sql.

Fix and test by Peter Otten.
2013-01-10 11:13:34 -05:00
R David Murray b52312923b #15545: fix sqlite3.iterdump regression on unsortable row_factory objects.
The fix for issue 9750 introduced a regression by sorting the row objects
returned by fetchall.  But if a row_factory such as sqlite3.Row is used, the
rows may not be sortable (in Python3), which leads to an exception.  The
sorting is still a nice idea, so the patch moves the sort into the sql.

Fix and test by Peter Otten.
2013-01-10 11:04:09 -05:00
Petri Lehtinen 8b24506534 Merge branch '3.2'
Closes #8033.
2012-02-21 13:59:40 +02:00
Petri Lehtinen 4fe85abab9 sqlite3: Fix 64-bit integer handling in user functions on 32-bit architectures
Closes #8033.
2012-02-21 13:49:50 +02:00
Petri Lehtinen aa2c670ee6 Merge branch '3.2'
Closes #11689.
2012-02-17 21:36:52 +02:00
Petri Lehtinen c86d9e2846 Fix a variable scoping error in an sqlite3 test
Closes #11689.
2012-02-17 21:31:02 +02:00
Petri Lehtinen c7551a16c7 Merge branch '3.2'
Closes #9750
2012-02-12 21:06:57 +02:00
Petri Lehtinen 51d04d1ba8 Fix sqlite3.Connection.iterdump on tables/fields with reserved names or quotes
Closes #9750
2012-02-12 21:05:31 +02:00
Petri Lehtinen bc35bebb45 Undocument and clean up sqlite3.OptimizedUnicode
Closes #13921.
2012-02-09 21:09:03 +02:00
Petri Lehtinen 4a84f58143 Issue #10811: Fix recursive usage of cursors. Instead of crashing, raise a ProgrammingError now. 2012-02-06 22:04:18 +02:00
Petri Lehtinen f854799d84 Make sqlite3 tests editable with Emacs
Change the coding declaration from ISO-8859-1 to iso-8859-1. Emacs
doesn't understand the former.
2012-02-02 20:47:59 +02:00
Petri Lehtinen 8940f6242c Merge branch 3.2
Closes #13676.
2012-02-01 22:21:05 +02:00