mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-02-07 12:50:32 +03:00
Propagate iterable exceptions to the executemany caller.
This commit is contained in:
parent
bd6a4139da
commit
3773b50bb3
|
@ -1,3 +1,8 @@
|
|||
2010-07-09 Daniele Varrazzo <daniele.varrazzo@gmail.com>
|
||||
|
||||
* psycopg/cursor_type.c: executemany() propagates exceptions raised by the
|
||||
iterable to the caller.
|
||||
|
||||
2010-05-20 Daniele Varrazzo <daniele.varrazzo@gmail.com>
|
||||
|
||||
* psycopg/typecast_datetime.c: Round seconds in historical timezones to
|
||||
|
|
|
@ -534,9 +534,14 @@ psyco_curs_executemany(cursorObject *self, PyObject *args, PyObject *kwargs)
|
|||
Py_XDECREF(iter);
|
||||
self->rowcount = rowcount;
|
||||
|
||||
if (!PyErr_Occurred()) {
|
||||
Py_INCREF(Py_None);
|
||||
return Py_None;
|
||||
}
|
||||
else {
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
#ifdef PSYCOPG_EXTENSIONS
|
||||
|
|
Loading…
Reference in New Issue
Block a user