Merge lp:~allenap/maas/pathlib-regression--bug-1604128 into lp:~maas-committers/maas/trunk

Proposed by Gavin Panella
Status: Merged
Approved by: Gavin Panella
Approved revision: no longer in the source branch.
Merged at revision: 5186
Proposed branch: lp:~allenap/maas/pathlib-regression--bug-1604128
Merge into: lp:~maas-committers/maas/trunk
Diff against target: 50 lines (+5/-5)
3 files modified
src/provisioningserver/refresh/tests/test_node_info_scripts.py (+2/-2)
src/provisioningserver/refresh/tests/test_refresh.py (+1/-1)
src/provisioningserver/utils/sshkey.py (+2/-2)
To merge this branch: bzr merge lp:~allenap/maas/pathlib-regression--bug-1604128
Reviewer Review Type Date Requested Status
Andres Rodriguez (community) Approve
Lee Trager (community) Approve
Review via email: mp+300392@code.launchpad.net

Commit message

Work around sudden loss of pathlib.Path.path property in Python 3.5.2 release.

To post a comment you must log in.
Revision history for this message
Lee Trager (ltrager) wrote :

LGTM!

review: Approve
Revision history for this message
Andres Rodriguez (andreserl) wrote :

LGTM!

review: Approve
Revision history for this message
Gavin Panella (allenap) wrote :

Thanks guys!

Revision history for this message
MAAS Lander (maas-lander) wrote :
Download full text (1.3 MiB)

The attempt to merge lp:~allenap/maas/pathlib-regression--bug-1604128 into lp:maas failed. Below is the output from the failed tests.

Hit:1 http://prodstack-zone-2.clouds.archive.ubuntu.com/ubuntu xenial InRelease
Get:2 http://prodstack-zone-2.clouds.archive.ubuntu.com/ubuntu xenial-updates InRelease [95.7 kB]
Get:3 http://security.ubuntu.com/ubuntu xenial-security InRelease [94.5 kB]
Hit:4 http://prodstack-zone-2.clouds.archive.ubuntu.com/ubuntu xenial-backports InRelease
Fetched 190 kB in 0s (389 kB/s)
Reading package lists...
sudo DEBIAN_FRONTEND=noninteractive apt-get -y \
    --no-install-recommends install apache2 archdetect-deb authbind bash bind9 bind9utils build-essential bzr bzr-builddeb chromium-browser chromium-chromedriver curl daemontools debhelper dh-apport dh-systemd distro-info dnsutils firefox freeipmi-tools git gjs ipython isc-dhcp-common libjs-angularjs libjs-jquery libjs-jquery-hotkeys libjs-yui3-full libjs-yui3-min libpq-dev make nodejs-legacy npm postgresql pxelinux python3-all python3-apt python3-bson python3-convoy python3-crochet python3-cssselect python3-curtin python3-dev python3-distro-info python3-django python3-django-nose python3-django-piston3 python3-dnspython python3-docutils python3-formencode python3-hivex python3-httplib2 python3-jinja2 python3-jsonschema python3-lxml python3-netaddr python3-netifaces python3-novaclient python3-oauth python3-oauthlib python3-openssl python3-paramiko python3-petname python3-pexpect python3-psycopg2 python3-pyinotify python3-pyparsing python3-pyvmomi python3-requests python3-seamicroclient python3-setuptools python3-simplestreams python3-sphinx python3-tempita python3-twisted python3-txtftp python3-tz python3-yaml python3-zope.interface python-bson python-crochet python-django python-django-piston python-djorm-ext-pgarray python-formencode python-lxml python-netaddr python-netifaces python-pocket-lint python-psycopg2 python-simplejson python-tempita python-twisted python-yaml socat syslinux-common tgt ubuntu-cloudimage-keyring wget xvfb
Reading package lists...
Building dependency tree...
Reading state information...
archdetect-deb is already the newest version (1.117ubuntu2).
authbind is already the newest version (2.1.1+nmu1).
build-essential is already the newest version (12.1ubuntu2).
curl is already the newest version (7.47.0-1ubuntu2).
debhelper is already the newest version (9.20160115ubuntu3).
distro-info is already the newest version (0.14build1).
freeipmi-tools is already the newest version (1.4.11-1ubuntu1).
git is already the newest version (1:2.7.4-0ubuntu1).
isc-dhcp-common is already the newest version (4.3.3-5ubuntu12).
libjs-angularjs is already the newest version (1.2.28-1ubuntu2).
libjs-jquery is already the newest version (1.11.3+dfsg-4).
libjs-yui3-full is already the newest version (3.5.1-1ubuntu3).
libjs-yui3-min is already the newest version (3.5.1-1ubuntu3).
make is already the newest version (4.1-6).
postgresql is already the newest version (9.5+173).
pxelinux is already the newest version (3:6.03+dfsg-11ubuntu1).
python-django is already the newest version (1.8.7-1ubuntu5).
python-formencode is already the newest version (1.3.0-0ubuntu5).
python-...

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/provisioningserver/refresh/tests/test_node_info_scripts.py'
2--- src/provisioningserver/refresh/tests/test_node_info_scripts.py 2016-06-14 10:36:41 +0000
3+++ src/provisioningserver/refresh/tests/test_node_info_scripts.py 2016-07-18 20:58:00 +0000
4@@ -817,9 +817,9 @@
5 script.write_text(VIRTUALITY_SCRIPT, "ascii")
6 script.chmod(0o700)
7 env = select_c_utf8_locale()
8- env["PATH"] = self.bindir.path
9+ env["PATH"] = str(self.bindir)
10 try:
11- return check_output((script.path,), stderr=STDOUT, env=env)
12+ return check_output((str(script),), stderr=STDOUT, env=env)
13 except CalledProcessError as error:
14 self.addDetail("output", text_content(
15 error.output.decode("utf-8", "replace")))
16
17=== modified file 'src/provisioningserver/refresh/tests/test_refresh.py'
18--- src/provisioningserver/refresh/tests/test_refresh.py 2016-06-15 02:17:49 +0000
19+++ src/provisioningserver/refresh/tests/test_refresh.py 2016-07-18 20:58:00 +0000
20@@ -377,7 +377,7 @@
21 with tempfile.TemporaryDirectory() as tmpdir:
22 tmpdir = Path(tmpdir).absolute()
23 return {
24- entry.path for entry in tmpdir.parent.iterdir()
25+ str(entry) for entry in tmpdir.parent.iterdir()
26 if entry.is_dir() and entry != tmpdir
27 }
28
29
30=== modified file 'src/provisioningserver/utils/sshkey.py'
31--- src/provisioningserver/utils/sshkey.py 2016-06-14 15:28:01 +0000
32+++ src/provisioningserver/utils/sshkey.py 2016-07-18 20:58:00 +0000
33@@ -136,7 +136,7 @@
34 try:
35 with open(os.devnull, "r") as devnull:
36 rfc4716key = check_output(
37- ("setsid", "-w", "ssh-keygen", "-e", "-f", keypath.path),
38+ ("setsid", "-w", "ssh-keygen", "-e", "-f", str(keypath)),
39 stdin=devnull, stderr=PIPE, env=env)
40 except CalledProcessError:
41 raise OpenSSHKeyError(
42@@ -146,7 +146,7 @@
43 try:
44 with open(os.devnull, "r") as devnull:
45 opensshkey = check_output(
46- ("setsid", "-w", "ssh-keygen", "-i", "-f", keypath.path),
47+ ("setsid", "-w", "ssh-keygen", "-i", "-f", str(keypath)),
48 stdin=devnull, stderr=PIPE, env=env)
49 except CalledProcessError:
50 # If this happens it /might/ be an OpenSSH bug. If we've managed