Daniele Varrazzo
9d15104868
Fixed adaptation of lists of empty lists
...
...somehow. Postgres doesn't support them and converts them into a
simple empty array. However this is not really our concern: the syntax
we return is valid.
Close #788
2018-10-30 00:29:18 +00:00
Daniele Varrazzo
eeef58b581
Don't barf on Composite passed to execute_values()
...
Close #794
2018-10-23 01:17:15 +01:00
Daniele Varrazzo
ed6f32999f
Fixed refcount in connection's readonly and deferrable getters
...
Close #790
2018-10-12 22:37:50 +01:00
Daniele Varrazzo
5abbcb23ca
Fixed infinite loop in pq_get_last_result after COPY
...
There will be an error downstream but we have to get out of this
function first.
Close #781
2018-10-10 23:23:56 +01:00
Daniele Varrazzo
ba54f1194a
Bump tests for selective closure of named cursor to pg 8.2
...
Previous versions don't support the features as they don't have the
pg_cursors view. But they are too old to care.
2018-07-24 19:02:13 +01:00
Daniele Varrazzo
43e35db988
Close named cursor if exist, even if we didn't run execute
...
Close #746
2018-07-21 18:32:02 +01:00
Daniele Varrazzo
85ec17a313
Merge branch 'fix-716' into maint_2_7
2018-05-20 17:05:25 +01:00
Daniele Varrazzo
7aea6b846e
Don't raise an exception closing an unused named cursor
...
Close #716
2018-05-20 14:05:58 +01:00
Daniele Varrazzo
f2896fe512
Set minimal postgres version for intervalstyle test
2018-05-20 13:42:30 +01:00
Daniele Varrazzo
51027dbd5f
Raise NotSupportedError fetching iso_8601 intervals
...
Previously it would have failed parsing and resulted in ValueError
Close #707
2018-05-20 13:24:40 +01:00
Jon Dufresne
42efb739d8
Fix use of "async" in test_cursor.py
...
"async" will be a keyword starting with Python 3.7. On Python 3.6, use
of "async" causes a deprecation warning. Use the alias "async_" instead.
2018-05-18 11:18:24 +01:00
Daniele Varrazzo
dcadc4c15a
Merge remote-tracking branch 'nested-array-nulls' into maint_2_7
2018-05-18 11:18:07 +01:00
Daniele Varrazzo
72e695ba1f
Skipped test on db version not supporting unicode identifiers
2018-05-14 03:11:11 +01:00
Daniele Varrazzo
799f8bded4
Hstore test fixed after adapting arrays dropped space after commas
2018-05-14 03:04:57 +01:00
Daniele Varrazzo
451dc8c5bf
Fixed adaptation of arrays of arrays of nulls
...
Close #325 , close #706 .
2018-05-14 02:38:44 +01:00
Daniele Varrazzo
8ad39c2712
Allow non-ascii chars in namedtuple fields
...
They can be valid chars in Python 3. Or maybe not? In which case Python
will throw an exception, but that's fine.
Fix regression introduced fixing #211
2018-05-13 23:51:21 +01:00
Daniele Varrazzo
214600fcc0
Allow strings subclasses in ensure_bytes
...
Fix #679
2018-02-20 17:33:12 +00:00
Daniele Varrazzo
e5da79fcc8
Convert fields names into valid Python identifiers in NamedTupleCursor
...
Close #211 .
2018-01-29 02:41:44 +00:00
Daniele Varrazzo
0a148dbe01
Silence warning on import failing a test
2018-01-29 00:51:05 +00:00
Daniele Varrazzo
8aaf8f1902
Fixed idempotence check changing connection characteristics
2018-01-11 02:08:27 +00:00
Daniele Varrazzo
f3685fe5ac
Fixed test in asian time zones
...
Fix #652
2018-01-11 08:53:57 +09:00
Daniele Varrazzo
9c5bf36791
'cursor.mogrify()' can be called on closed cursors
...
Fix #579 .
2018-01-10 23:26:11 +00:00
Daniele Varrazzo
a5fd594ea4
Collect rowcount in executemany even when discarding results
...
Closes #633 .
2017-11-29 15:38:02 +00:00
Jon Dufresne
390e43fcb1
Use modern except syntax throughout project
...
The syntax "except Exception, exc:" is deprecated. All Python versions
supported by psycopg2 support the newer, modern syntax. Forward
compatible with future Python versions.
2017-11-20 20:00:35 -08:00
Federico Di Gregorio
5983b96c55
Don't cast point arrays to float arrays ( fixes : #613 )
2017-11-16 10:07:27 +01:00
Daniele Varrazzo
775de754cf
Added back timestamptz[] default cast
...
It was registered as side effect of an excessive definition that got
cleaned up in 338dbe70a6
.
Looking at other removed redundant type oids, this was the only one
missing from the `string_types` map.
Close #578 .
2017-07-24 14:23:36 +01:00
Daniele Varrazzo
cfa0509d7e
Deal with E'' strings comparisons in a few other tests
2017-07-22 03:15:06 +01:00
Daniele Varrazzo
d619baf000
Skipped a couple of test with unsupported postgres features
2017-07-22 02:09:24 +01:00
Daniele Varrazzo
d2e86db8fb
Merge branch 'fix-554'
2017-06-17 03:34:01 +01:00
Daniele Varrazzo
1a97445471
Accept Composable in start_replication_expert()
...
Close #554
2017-06-17 03:30:44 +01:00
Daniele Varrazzo
30d89da4fa
Ignore spurious output in test with Python debug build
2017-06-17 03:20:09 +01:00
Daniele Varrazzo
2b5e131831
Merge branch 'fix-558'
2017-06-16 19:41:52 +01:00
Daniele Varrazzo
70a2d2238e
Consider redshift interval supported after further tests
2017-06-16 19:39:18 +01:00
Daniele Varrazzo
789eb64f3a
Added Json.prepare()
...
Close #562
2017-06-16 01:37:49 +01:00
Daniele Varrazzo
315f72862c
Parse a number as microseconds when casting interval
...
Should close #558 , but I'm curious to know if a number is returned
for interval < 1 day too (which wouldn't trigger the overflow, but will
finish parsing with part=0).
2017-06-16 00:54:38 +01:00
Daniele Varrazzo
7ae2cb5cd0
Don't force a valid return code for the test
...
Windows returns 22, Linux returns 1
2017-06-15 17:39:00 +01:00
Daniele Varrazzo
de843ef756
Added test to reproduce bug #551
2017-06-15 17:22:32 +01:00
Daniele Varrazzo
6e5abf33f2
Merge branch 'fix-547'
2017-04-19 01:34:39 +01:00
Daniele Varrazzo
a7e3f46431
Merge remote-tracking branch 'fix_lobject_factory'
2017-04-19 01:06:24 +01:00
Daniele Varrazzo
248e653c9e
Fixed args parsing in ReplicationCursor.consume_stream()
...
Close #547 .
2017-04-19 01:01:59 +01:00
Frazer McLean
9e5621698f
Python < 3.2 doesn’t have assertIsInstance
2017-04-16 03:44:21 +02:00
Frazer McLean
7b3ea43e92
Handle lobject mode=None correctly
2017-04-16 03:20:31 +02:00
Frazer McLean
38cd720369
Fix name of lobject keyword argument
2017-04-16 03:12:18 +02:00
Daniele Varrazzo
cd095ef0ee
Added test to verify callback errors in named cursors
...
They work fine.
2017-04-05 14:54:07 +01:00
Daniele Varrazzo
47f5e97759
Added test to verify #410
...
The 'unknown error' happens on query.
2017-04-05 14:54:07 +01:00
Daniele Varrazzo
7214c6652e
Return objects with timezone parsing infinity timestamptz
...
Close #536 .
2017-03-22 03:03:02 +00:00
Daniele Varrazzo
f9b36433fb
Merge branch 'fix-528'
2017-03-16 04:24:17 +00:00
Daniele Varrazzo
9f160fd820
Obscure the password on url dsn too
...
Note that we don't leak anymore the password length.
Fix #528
2017-03-16 03:53:40 +00:00
Daniele Varrazzo
3bfbd3a0a5
Added test to verify sql objects work with copy_expert()
...
I'll be honest: I lucked out, I didn't think about this combination. But
maybe sheer luck, maybe using common code paths, it just works. Let's
make it stays so.
2017-03-16 00:55:20 +00:00
Daniele Varrazzo
cc047a445a
Added tests to verify the password is obscured
...
The url test fails: see issue #528
2017-03-15 16:00:40 +00:00