Merge lp:~dobey/ubuntuone-dev-tools/twisted-regressed into lp:ubuntuone-dev-tools

Proposed by dobey
Status: Merged
Approved by: dobey
Approved revision: 107
Merged at revision: 107
Proposed branch: lp:~dobey/ubuntuone-dev-tools/twisted-regressed
Merge into: lp:ubuntuone-dev-tools
Diff against target: 40 lines (+7/-3)
2 files modified
ubuntuone/devtools/testcases/tests/test_squid_testcase.py (+5/-1)
ubuntuone/devtools/utils.py (+2/-2)
To merge this branch: bzr merge lp:~dobey/ubuntuone-dev-tools/twisted-regressed
Reviewer Review Type Date Requested Status
Mike McCracken (community) Approve
Review via email: mp+201250@code.launchpad.net

Commit message

New twisted breaks API, so update the code to deal with it.

To post a comment you must log in.
Revision history for this message
Mike McCracken (mikemc) wrote :

looks good, tests run for me on trusty

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'ubuntuone/devtools/testcases/tests/test_squid_testcase.py'
2--- ubuntuone/devtools/testcases/tests/test_squid_testcase.py 2013-02-08 19:38:02 +0000
3+++ ubuntuone/devtools/testcases/tests/test_squid_testcase.py 2014-01-10 20:05:28 +0000
4@@ -35,6 +35,10 @@
5 from ubuntuone.devtools.testcases import skipIfOS
6 from ubuntuone.devtools.testcases.squid import SquidTestCase
7
8+try:
9+ from urllib.parse import urlparse
10+except ImportError:
11+ from urlparse import urlparse
12
13 SAMPLE_RESOURCE = "<p>Hello World!</p>"
14 SIMPLERESOURCE = "simpleresource"
15@@ -82,7 +86,7 @@
16
17 def _connect(self, url, contextFactory):
18 """Perform the connection."""
19- scheme, _, _, _ = client._parse(url)
20+ scheme, _, _, _, _, _ = urlparse(url)
21 # pylint: disable=E1101
22 if scheme == 'https':
23 from twisted.internet import ssl
24
25=== modified file 'ubuntuone/devtools/utils.py'
26--- ubuntuone/devtools/utils.py 2012-08-13 15:18:00 +0000
27+++ ubuntuone/devtools/utils.py 2014-01-10 20:05:28 +0000
28@@ -135,10 +135,10 @@
29 for _arg in _args:
30 try:
31 if has_default:
32- l_opt, s_opt, default, doc = unpack_padded(4, _arg)
33+ l_opt, s_opt, default, doc, _ = unpack_padded(5, _arg)
34 else:
35 default = False
36- l_opt, s_opt, doc = unpack_padded(3, _arg)
37+ l_opt, s_opt, doc, _ = unpack_padded(4, _arg)
38 except ValueError:
39 raise ValueError('Failed to parse argument: %s' % _arg)
40 if not l_opt:

Subscribers

People subscribed via source and target branches

to all changes: