mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-01-31 09:24:07 +03:00
Fixed #129.
This commit is contained in:
parent
168d9c36af
commit
bc580e3383
|
@ -1,5 +1,8 @@
|
||||||
2006-09-30 Federico Di Gregorio <fog@initd.org>
|
2006-09-30 Federico Di Gregorio <fog@initd.org>
|
||||||
|
|
||||||
|
* ZpsycopgDA/DA.py: we now split on GMT+, GMT-, + or -. This should
|
||||||
|
fix bug #129.
|
||||||
|
|
||||||
* psycopg/adapter_datetime.py: now TimeFromTicks and
|
* psycopg/adapter_datetime.py: now TimeFromTicks and
|
||||||
TimestampFromTicks both accept fractionary seconds (fixes #130).
|
TimestampFromTicks both accept fractionary seconds (fixes #130).
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,8 @@
|
||||||
# See the LICENSE file for details.
|
# See the LICENSE file for details.
|
||||||
|
|
||||||
|
|
||||||
ALLOWED_PSYCOPG_VERSIONS = ('2.0.1', '2.0.2', '2.0.3', '2.0.4', '2.0.5')
|
ALLOWED_PSYCOPG_VERSIONS = ('2.0.1', '2.0.2', '2.0.3', '2.0.4', '2.0.5',
|
||||||
|
'2.0.6')
|
||||||
|
|
||||||
import sys
|
import sys
|
||||||
import time
|
import time
|
||||||
|
@ -220,7 +221,7 @@ for icon in ('table', 'view', 'stable', 'what', 'field', 'text', 'bin',
|
||||||
# convert an ISO timestamp string from postgres to a Zope DateTime object
|
# convert an ISO timestamp string from postgres to a Zope DateTime object
|
||||||
def _cast_DateTime(iso, curs):
|
def _cast_DateTime(iso, curs):
|
||||||
if iso:
|
if iso:
|
||||||
return DateTime(re.split("GMT\+?|GMT-?", iso)[0])
|
return DateTime(re.split("GMT\+?|GMT-?|\+|-", iso)[0])
|
||||||
|
|
||||||
# this will split us into [date, time, GMT/AM/PM(if there)]
|
# this will split us into [date, time, GMT/AM/PM(if there)]
|
||||||
# dt = str.split(' ')
|
# dt = str.split(' ')
|
||||||
|
|
Loading…
Reference in New Issue
Block a user