[issue21584] Unraised overflow error in sqlite3.Row indexing

2014-05-26 Thread Serhiy Storchaka

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



[issue21584] Unraised overflow error in sqlite3.Row indexing

2014-05-26 Thread Serhiy Storchaka

Serhiy Storchaka added the comment:

Actually this happens after applying the patch from issue10203.

--
resolution:  - not a bug
status: open - closed

___
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