New submission from Serhiy Storchaka: When integer index overflows C long, sqlite3.Row.__getitem__() doesn't raise an exception. Instead overflow exception is raised later.
>>> import sqlite3 >>> con = sqlite3.connect(":memory:") >>> con.row_factory = sqlite3.Row >>> row = con.execute("select 1 as a, 2 as b").fetchone() >>> row[2**1000] 2 >>> OverflowError: Python int too large to convert to C long ---------- assignee: serhiy.storchaka components: Extension Modules keywords: easy messages: 219174 nosy: Claudiu.Popa, ghaering, serhiy.storchaka priority: normal severity: normal stage: needs patch status: open title: Unraised overflow error in sqlite3.Row indexing type: behavior versions: Python 2.7, Python 3.3, Python 3.4 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue21584> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com