Merge lp:~cjwatson/python-pgbouncer/py3 into lp:python-pgbouncer

Proposed by Colin Watson
Status: Merged
Merged at revision: 15
Proposed branch: lp:~cjwatson/python-pgbouncer/py3
Merge into: lp:python-pgbouncer
Prerequisite: lp:~cjwatson/python-pgbouncer/tox
Diff against target: 65 lines (+7/-2)
5 files modified
.bzrignore (+1/-0)
NEWS.txt (+1/-0)
pgbouncer/fixture.py (+2/-2)
setup.py (+2/-0)
tox.ini (+1/-0)
To merge this branch: bzr merge lp:~cjwatson/python-pgbouncer/py3
Reviewer Review Type Date Requested Status
William Grant code Approve
Review via email: mp+368551@code.launchpad.net

Commit message

Add Python 3 support.

To post a comment you must log in.
Revision history for this message
William Grant (wgrant) :
review: Approve (code)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file '.bzrignore'
--- .bzrignore 2019-06-07 15:29:45 +0000
+++ .bzrignore 2019-06-07 15:29:45 +0000
@@ -1,5 +1,6 @@
1./.tox1./.tox
2./MANIFEST2./MANIFEST
3./pgbouncer.egg-info3./pgbouncer.egg-info
4__pycache__
4TAGS5TAGS
5tags6tags
67
=== modified file 'NEWS.txt'
--- NEWS.txt 2019-06-07 15:29:45 +0000
+++ NEWS.txt 2019-06-07 15:29:45 +0000
@@ -3,6 +3,7 @@
33
4- Use postgresfixture to test against multiple PostgreSQL versions.4- Use postgresfixture to test against multiple PostgreSQL versions.
5- Switch to tox.5- Switch to tox.
6- Add Python 3 support.
67
70.0.8 (2012-08-20)80.0.8 (2012-08-20)
8==================9==================
910
=== modified file 'pgbouncer/fixture.py'
--- pgbouncer/fixture.py 2012-08-13 20:53:04 +0000
+++ pgbouncer/fixture.py 2019-06-07 15:29:45 +0000
@@ -52,11 +52,11 @@
52 port, and the time it actually gets used), but for the purposes for which52 port, and the time it actually gets used), but for the purposes for which
53 this function gets used it isn't a problem in practice.53 this function gets used it isn't a problem in practice.
54 """54 """
55 sockets = map(lambda _: socket.socket(), xrange(n))55 sockets = [socket.socket() for _ in range(n)]
56 try:56 try:
57 for s in sockets:57 for s in sockets:
58 s.bind(('localhost', 0))58 s.bind(('localhost', 0))
59 return map(lambda s: s.getsockname()[1], sockets)59 return [s.getsockname()[1] for s in sockets]
60 finally:60 finally:
61 for s in sockets:61 for s in sockets:
62 s.close()62 s.close()
6363
=== modified file 'setup.py'
--- setup.py 2019-06-07 15:29:45 +0000
+++ setup.py 2019-06-07 15:29:45 +0000
@@ -37,6 +37,8 @@
37 'License :: OSI Approved :: GNU Affero General Public License v3',37 'License :: OSI Approved :: GNU Affero General Public License v3',
38 'Operating System :: OS Independent',38 'Operating System :: OS Independent',
39 'Programming Language :: Python',39 'Programming Language :: Python',
40 'Programming Language :: Python :: 2',
41 'Programming Language :: Python :: 3',
40 ],42 ],
41 install_requires = [43 install_requires = [
42 'fixtures',44 'fixtures',
4345
=== modified file 'tox.ini'
--- tox.ini 2019-06-07 15:29:45 +0000
+++ tox.ini 2019-06-07 15:29:45 +0000
@@ -1,6 +1,7 @@
1[tox]1[tox]
2envlist =2envlist =
3 py273 py27
4 py35
45
5[testenv]6[testenv]
6deps =7deps =

Subscribers

People subscribed via source and target branches

to status/vote changes: