mirror of
https://github.com/psycopg/psycopg2.git
synced 2025-02-01 01:44:07 +03:00
Merge branch 'fix-libpq-version' into maint_2_7
This commit is contained in:
commit
5f0d411d11
4
NEWS
4
NEWS
|
@ -5,8 +5,10 @@ What's new in psycopg 2.7.4
|
||||||
^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
- Fixed Solaris 10 support (:ticket:`#532`).
|
- Fixed Solaris 10 support (:ticket:`#532`).
|
||||||
- Fixed `MinTimeLoggingCursor` on Python 3 (:ticket:`#609`).
|
- Fixed `!MinTimeLoggingCursor` on Python 3 (:ticket:`#609`).
|
||||||
- Fixed parsing of array of points as floats (:ticket:`#613`).
|
- Fixed parsing of array of points as floats (:ticket:`#613`).
|
||||||
|
- Fixed `~psycopg2.__libpq_version__` building with libpq >= 10.1
|
||||||
|
(:ticket:`632`).
|
||||||
|
|
||||||
|
|
||||||
What's new in psycopg 2.7.3.2
|
What's new in psycopg 2.7.3.2
|
||||||
|
|
10
setup.py
10
setup.py
|
@ -64,7 +64,7 @@ except ImportError:
|
||||||
# Take a look at http://www.python.org/dev/peps/pep-0440/
|
# Take a look at http://www.python.org/dev/peps/pep-0440/
|
||||||
# for a consistent versioning pattern.
|
# for a consistent versioning pattern.
|
||||||
|
|
||||||
PSYCOPG_VERSION = '2.7.4.dev0'
|
PSYCOPG_VERSION = '2.7.4.dev1'
|
||||||
|
|
||||||
|
|
||||||
# note: if you are changing the list of supported Python version please fix
|
# note: if you are changing the list of supported Python version please fix
|
||||||
|
@ -197,8 +197,7 @@ or with the pg_config option in 'setup.cfg'.
|
||||||
return None
|
return None
|
||||||
|
|
||||||
pg_first_inst_key = winreg.OpenKey(reg,
|
pg_first_inst_key = winreg.OpenKey(reg,
|
||||||
'SOFTWARE\\PostgreSQL\\Installations\\'
|
'SOFTWARE\\PostgreSQL\\Installations\\' + first_sub_key_name)
|
||||||
+ first_sub_key_name)
|
|
||||||
try:
|
try:
|
||||||
pg_inst_base_dir = winreg.QueryValueEx(
|
pg_inst_base_dir = winreg.QueryValueEx(
|
||||||
pg_first_inst_key, 'Base Directory')[0]
|
pg_first_inst_key, 'Base Directory')[0]
|
||||||
|
@ -422,11 +421,14 @@ class psycopg_build_ext(build_ext):
|
||||||
m = verre.match(pgversion)
|
m = verre.match(pgversion)
|
||||||
if m:
|
if m:
|
||||||
pgmajor, pgminor, pgpatch = m.group(1, 2, 3)
|
pgmajor, pgminor, pgpatch = m.group(1, 2, 3)
|
||||||
|
# Postgres >= 10 doesn't have pgminor anymore.
|
||||||
|
pgmajor = int(pgmajor)
|
||||||
|
if pgmajor >= 10:
|
||||||
|
pgminor, pgpatch = None, pgminor
|
||||||
if pgminor is None or not pgminor.isdigit():
|
if pgminor is None or not pgminor.isdigit():
|
||||||
pgminor = 0
|
pgminor = 0
|
||||||
if pgpatch is None or not pgpatch.isdigit():
|
if pgpatch is None or not pgpatch.isdigit():
|
||||||
pgpatch = 0
|
pgpatch = 0
|
||||||
pgmajor = int(pgmajor)
|
|
||||||
pgminor = int(pgminor)
|
pgminor = int(pgminor)
|
||||||
pgpatch = int(pgpatch)
|
pgpatch = int(pgpatch)
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user