Daniele Varrazzo
3752880b7b
Fixed attempt of closing an already closed lobject on dealloc
...
This results in a "null without exception set" in the corrent state, which
is caused by the connection being unexpectedly closed anyway.
2014-04-05 16:03:06 +01:00
Daniele Varrazzo
2e55b35d5d
Don't set an exception witout GIL closing lobjects with a bad conn
...
We ended up in this branch only for an excessively aggressive closing
of the transaction that now I'm going to fix.
2014-04-05 16:03:06 +01:00
Daniele Varrazzo
696d123550
Close a connection if PQexec returned NULL
...
This happens for Socket connections, not for TCP ones, where a result
containing an error is returned and correctly handled by pq_raise()
Closes ticket #196 but not #192 : poll() still doesn't change the
connection closed.
2014-04-05 16:03:06 +01:00
Daniele Varrazzo
a31c1a1722
Allow get_transaction_status on closed connections
...
It's a local operation and the libpq functions has a NULL guard.
2014-04-05 16:02:43 +01:00
Daniele Varrazzo
9036299d54
Avoid printing the typecast name in debug statement
...
The way we were doing it is unsafe and causes assertion failures on Py3.
Fixes ticket #188
2014-04-04 19:25:09 +01:00
Daniele Varrazzo
ca98167ae4
Fixed use of Python object with refcount 0 in cursor_init
...
Caused segfault running test_cursor.CursorTests.test_invalid_name under
Python 3.4 built in debug mode.
2014-04-04 19:20:08 +01:00
Daniele Varrazzo
81443c3a65
Work around pip issue #1630 breaking 'pip -e git+url'
...
https://github.com/pypa/pip/issues/1630
Fixes ticket #18 (opened in 2010!)
2014-04-04 18:07:05 +01:00
Daniele Varrazzo
33f2301772
Clarify in the docs that mogrify() and query always return bytes
2014-04-03 02:46:54 +01:00
Daniele Varrazzo
e9661bcde5
Fixed bug number typo in NEWS file
2014-04-03 02:45:57 +01:00
Daniele Varrazzo
a8fdc74090
Fixed overflow opening a lobject with an oid not fitting in a signed int
...
Fixes 🎫 `203`.
2014-04-03 02:35:56 +01:00
Daniele Varrazzo
dfacc483b5
Dropped unneeded pass in test
2014-04-03 02:32:05 +01:00
Daniele Varrazzo
25e3a5f744
Explicit the fact that closed connections have undefined status
2014-04-03 02:07:38 +01:00
Daniele Varrazzo
e7fc7f31b9
Fixed dsn and closed attributes in failing connection subclasses.
...
From ticket #192 discussion.
2014-04-03 01:42:35 +01:00
Erwin de Keijzer
0258e90ef0
Fixed DNS typo in examples
2014-03-24 18:36:33 +01:00
Daniele Varrazzo
7b82be936d
Don't segfault on uninitialized cursor
...
It can happen with bad cursor subclasses not calling super's init. Raise
an exception instead of segfaulting.
Closes #195
2014-02-26 19:41:59 +00:00
Daniele Varrazzo
618f7e41de
Use the do-while 0 idiom for cursor guards macro
2014-02-26 19:31:27 +00:00
Daniele Varrazzo
3c893606f5
Merge branch 'ticket-194'
2014-02-24 15:20:13 +00:00
Daniele Varrazzo
79e84e432a
Bug #194 confirmed fixed: newsfile updated.
2014-02-24 15:20:01 +00:00
Daniele Varrazzo
63e36e22d2
Set the connection async before polling for connection
...
It should fix ticket #194
2014-02-24 15:20:01 +00:00
Daniele Varrazzo
ca99579b76
Set the connection async earlier in green mode
...
The moment it is called shouldn't have really changed, but it's more
explicit when it happens. Previously it was sort of obfuscated behind a
roundtrip through the green callback and poll.
2014-02-24 15:20:01 +00:00
Daniele Varrazzo
283dbccf56
Merge branch 'range_sort'
2014-02-22 23:02:19 +00:00
Daniele Varrazzo
dd9e476353
Fixed error message on range parsing failed
2014-02-22 23:02:07 +00:00
Daniele Varrazzo
8d2744c550
Mention Range order in the news file
2014-02-22 23:01:22 +00:00
Daniele Varrazzo
212f4e3538
Docs wordsmithing about Range order
2014-02-22 23:01:02 +00:00
Daniele Varrazzo
8937c635df
Hardcode the list of attributes to be used in comparison
...
Comparing Range subclasses may lead to surprises.
2014-02-22 21:52:44 +00:00
Daniele Varrazzo
4545d1636c
Added implementation for Range gt and ge operators
...
Using a common implementation for all the operators. Note that lt is the
one used by sort so it's nice it's the fastest.
2014-02-22 21:51:28 +00:00
Daniele Varrazzo
6192a4fb17
Added str() for the Json adapter
...
Fixes ticket #191 .
2014-02-22 20:45:35 +00:00
Chris Withers
6cd0647da9
documentation changes now that Range objects can be ordered
2014-02-18 21:24:59 +00:00
Chris Withers
e60266c4c5
New implementation of Range sorting that works for Python 2.5 to 3.3, at least.
2014-02-18 20:55:00 +00:00
Chris Withers
bae508ffa6
Coding style changes.
2014-02-14 07:46:32 +00:00
Chris Withers
d469c32503
Provide a stable and consistent sort order for Range objects.
...
This matches postgres server-side behaviour and helps client applications that need to sort based on the primary key of tables where the primary key is or contains a range.
2014-02-12 08:11:59 +00:00
Daniele Varrazzo
66f85b5832
Merge branch 'outputres'
2014-01-14 21:54:28 +00:00
Daniele Varrazzo
a35b743af7
Mention outputres fix in NEWS file
2014-01-14 21:52:42 +00:00
Daniele Varrazzo
4ed9dc1435
Added doc notes about how to avoid JSON parsing
...
Added FAQ too as it has bitten more than one user
(see tickets #172 , #190 ).
2014-01-14 18:33:05 +00:00
James Emerton
58c98deebb
Fallback when get_ext_fullpath() is unavailable
2014-01-10 13:41:16 -08:00
James Emerton
9100ad3e8f
Use get_ext_fullpath() for -outputresource
...
The manifest fixup was relying on the extension name being "_psycopg.pyd" which effectively prevents building with --debug as the extension name becomes "_psycopg_d.pyd" in this instance.
2014-01-10 11:56:14 -08:00
Daniele Varrazzo
85b1914ad6
Fixed dealloc of lobject->smode
...
I put it by mistake into the in the self->conn checked block in the
previous commit.
2013-11-27 13:00:16 +00:00
Daniele Varrazzo
e11d0d39ec
Check connection type in lobject init
...
Fixes ticket #187 .
2013-11-27 12:44:28 +00:00
Daniele Varrazzo
6ab1ec1c37
Typo fixes and improvements to new_array_type() docs
2013-10-21 15:27:31 +01:00
Daniele Varrazzo
bc70902ea5
Use bytestrings in infinite dates adapter example
...
Returning strings would result in unclear tracebacks on Py3 (see ticket #163 ).
2013-10-21 14:30:25 +01:00
Daniele Varrazzo
2e3833f7fb
Really test named cursors in test_scroll_named()
2013-10-16 19:10:21 +01:00
Daniele Varrazzo
5c99d2a456
Document that named cursors don't raise an exception going out-of-bound
...
See issue #174 for the details.
2013-10-16 19:10:20 +01:00
Daniele Varrazzo
a0a63e3ac7
Document that using %, (, ) in the placeholder name is not supported
2013-10-16 17:50:11 +01:00
Daniele Varrazzo
1e623a951c
Meaningful connection errors report a meaningful message
...
Fixes issue #173 .
2013-10-16 17:50:10 +01:00
Daniele Varrazzo
345077d5f7
Fixed pickling of exceptions with no pgerror/pgcode set
...
Fixes ticket #170 .
2013-07-19 16:05:59 +01:00
Daniele Varrazzo
81e8b869d0
Fixed titles in newsfile
...
The first title at the same level of the main releases helps getting a
more regular ToC in the docs main page.
2013-07-19 16:02:31 +01:00
Daniele Varrazzo
497247a528
Fixed doc index entry for infinite dates
2013-06-23 02:14:01 +01:00
Daniele Varrazzo
921b676471
Untrack the connection before closing to avoid possible double-free
...
From Gangadharan S.A. Fixes issue #166 .
2013-06-20 16:35:43 +01:00
Daniele Varrazzo
83c5d12cf1
Added doc example to convert date.max to infinity
...
See issue #163 .
2013-06-18 15:00:30 +01:00
Daniele Varrazzo
ea08f7e7c7
Merge branch 'range_eq_typerror'
2013-06-18 14:14:01 +01:00