Merge lp:~jderose/microfiber/python2 into lp:microfiber

Proposed by Jason Gerard DeRose
Status: Merged
Merged at revision: 70
Proposed branch: lp:~jderose/microfiber/python2
Merge into: lp:microfiber
Diff against target: 62 lines (+22/-5)
2 files modified
debian/control (+14/-3)
debian/rules (+8/-2)
To merge this branch: bzr merge lp:~jderose/microfiber/python2
Reviewer Review Type Date Requested Status
David Jordan Approve
Review via email: mp+72672@code.launchpad.net

Description of the change

So this changes things so:

 * We also produce a `python-microfiber` package for Python2

 * We also run the tests under python2.7

I know I'm not running the python2.7 tests in the most proper way, but this is a stopgap anyway. We'll probably release microfiber 11.09 with python2 support, and then go for Python3 only so we can clean up the code a bit. Or we could try 3to2.py.

Anyway, but having microfiber for Python2 is important as we can more easily migrate dmedia to Python3 piecewise... by first switching dmedia to microfiber, which supports both Python2 and Python3.

To post a comment you must log in.
Revision history for this message
Jason Gerard DeRose (jderose) wrote :

Ah, one thing to note. I learned to use:

  $(shell py3versions -vr)

Rather than:

  $(shell py3versions -sv)

The `-vr` flags mean that the versions are selected based on the X-Python3-Version header in debian/control. `-sv` means it gets installed for all available versions of Python.

Revision history for this message
David Jordan (dmj726) wrote :

Looks good. Should definitely help us migrate to python 3.

review: Approve
Revision history for this message
Jason Gerard DeRose (jderose) wrote :

Thanks, David! :-D

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/control'
2--- debian/control 2011-08-10 13:33:42 +0000
3+++ debian/control 2011-08-24 06:00:08 +0000
4@@ -2,15 +2,26 @@
5 Section: python
6 Priority: optional
7 Maintainer: Jason Gerard DeRose <jderose@novacut.com>
8-Build-Depends: debhelper (>= 8.1), python3 (>= 3.2)
9+Build-Depends: debhelper (>= 8.1), python3 (>= 3.2), python (>= 2.7)
10 Standards-Version: 3.9.1
11-X-Python-Version: 3.2
12+X-Python-Version: 2.7
13 X-Python3-Version: 3.2
14 Homepage: https://launchpad.net/microfiber
15
16 Package: python3-microfiber
17 Architecture: all
18-Depends: ${misc:Depends}, ${python3:Depends}
19+Depends: ${misc:Depends}, python3 (>= 3.2)
20+Description: fabric for a lightweight Couch
21+ microfiber is an abstract adapter for making HTTP requests to an arbitrary JSON
22+ loving REST API like CouchDB. Rather than wrapping the API in a bunch of
23+ one-off methods, microfiber just makes it super easy to call any part of the
24+ CouchDB REST API, current or future. This approach allows microfiber to be
25+ very simple and basically maintenance free as it requires no changes to support
26+ new additions to the CouchDB API.
27+
28+Package: python-microfiber
29+Architecture: all
30+Depends: ${misc:Depends}, python (>= 2.7)
31 Description: fabric for a lightweight Couch
32 microfiber is an abstract adapter for making HTTP requests to an arbitrary JSON
33 loving REST API like CouchDB. Rather than wrapping the API in a bunch of
34
35=== modified file 'debian/rules'
36--- debian/rules 2011-08-10 13:31:19 +0000
37+++ debian/rules 2011-08-24 06:00:08 +0000
38@@ -3,16 +3,22 @@
39 PYTHON3=$(shell py3versions -vr)
40
41 %:
42- dh $@ --with=python3
43+ dh $@ --with=python3 --with=python2
44
45 test-python%:
46 python$* setup.py test -vv
47+ python2.7 setup.py test -vv
48
49 override_dh_auto_install:
50- for pyvers in $(shell py3versions -sv); do \
51+ for pyvers in $(shell py3versions -vr); do \
52 python$$pyvers setup.py install \
53 --install-layout=deb \
54 --root $(CURDIR)/debian/python3-microfiber; \
55 done
56+ for pyvers in $(shell pyversions -vr); do \
57+ python$$pyvers setup.py install \
58+ --install-layout=deb \
59+ --root $(CURDIR)/debian/python-microfiber; \
60+ done
61
62 override_dh_auto_test: $(PYTHON3:%=test-python%)

Subscribers

People subscribed via source and target branches