Merge lp:~blake-rouse/maas/fix-1499749-1.8 into lp:maas/1.8

Proposed by Blake Rouse
Status: Merged
Approved by: Blake Rouse
Approved revision: no longer in the source branch.
Merged at revision: 4045
Proposed branch: lp:~blake-rouse/maas/fix-1499749-1.8
Merge into: lp:maas/1.8
Diff against target: 24 lines (+7/-1)
1 file modified
src/maasserver/bootresources.py (+7/-1)
To merge this branch: bzr merge lp:~blake-rouse/maas/fix-1499749-1.8
Reviewer Review Type Date Requested Status
Blake Rouse (community) Approve
Review via email: mp+272408@code.launchpad.net

Commit message

checksummer is no longer in the simplestreams.util module.

This plays it defensively and checks both the simplestreams.util and simplestreams.checksum_util modules for checksummer.

To post a comment you must log in.
Revision history for this message
Blake Rouse (blake-rouse) wrote :

Self-approving backport.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'src/maasserver/bootresources.py'
2--- src/maasserver/bootresources.py 2015-06-02 08:46:21 +0000
3+++ src/maasserver/bootresources.py 2015-09-25 14:39:44 +0000
4@@ -98,6 +98,12 @@
5 from twisted.python import log
6
7
8+try:
9+ from simplestreams.checksum_util import checksummer
10+except ImportError:
11+ from simplestreams.util import checksummer
12+
13+
14 maaslog = get_maas_logger("bootresources")
15
16 # Used by maasserver.middleware.AccessMiddleware to allow
17@@ -653,7 +659,7 @@
18 """Writes the data from the given reader, into the object storage
19 for the given `BootResourceFile`."""
20 ident = self.get_resource_file_log_identifier(rfile)
21- cksummer = sutil.checksummer(
22+ cksummer = checksummer(
23 {'sha256': rfile.largefile.sha256})
24 maaslog.debug("Finalizing boot image %s.", ident)
25

Subscribers

People subscribed via source and target branches

to all changes: