Skip to content
Commits on Source (3)
  • Jessica Clarke's avatar
    Fix diff_meta_data reporting every file as new and removed · 14c81dc7
    Jessica Clarke authored and Holger Levsen's avatar Holger Levsen committed
    
    
    This regressed in 0b47bf88, which
    erroneously used the original trees rather than the modified copies.
    
    Signed-off-by: default avatarHolger Levsen <holger@layer-acht.org>
    14c81dc7
  • Holger Levsen's avatar
    add changelog entry for James · b1738ebd
    Holger Levsen authored
    
    
    Signed-off-by: default avatarHolger Levsen <holger@layer-acht.org>
    b1738ebd
  • Nis Martensen's avatar
    piuparts-report: fix pickle.loading str from python2 · fda3b882
    Nis Martensen authored and Holger Levsen's avatar Holger Levsen committed
    
    
    piuparts-report may encounter old md5cache files pickled by python2 in
    text mode. Loading such files may fail if there are non-ascii
    characters. The existing cache files involved in generating the reports
    on piuparts.debian.org most likely use utf-8 encoding, so let's use that
    instead of the default assumption 'ascii'.
    
    Should fix:
    
    Traceback (most recent call last):
      File "/srv/piuparts.debian.org/share/piuparts/piuparts-report", line 1911, in <module>
        main()
      File "/srv/piuparts.debian.org/share/piuparts/piuparts-report", line 1851, in main
        section.generate_output(output_directory, section_names, problem_list, web_host)
      File "/srv/piuparts.debian.org/share/piuparts/piuparts-report", line 1660, in generate_output
        self.generate_html()
      File "/srv/piuparts.debian.org/share/piuparts/piuparts-report", line 1563, in generate_html
        self._md5cache['old'] = pickle.load(f)
    UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 71: ordinal not in range(128)
    
    Signed-off-by: default avatarHolger Levsen <holger@layer-acht.org>
    fda3b882
......@@ -58,6 +58,9 @@ piuparts (1.1.0) UNRELEASED; urgency=medium
detect_well_known_errors, piupartslib/(dependencyparser|packagesdb):
several fixes and improvements related to porting to python3.
[ James Clarke ]
* piuparts: Fix diff_meta_data reporting every file as new and removed.
-- Holger Levsen <holger@debian.org> Sun, 07 Jul 2019 17:15:41 +0200
piuparts (1.0.1) unstable; urgency=medium
......
......@@ -7,7 +7,7 @@
<tr class="normalrow">
<td class="contentcell2">
<b>2019-12-27</b>
piuparts.debian.org switch to python3 done. Many thanks to all who contributed: Herbert Parentes Fortes Neto, Thomas Goirand, Mattia Rizzolo, Holger Levsen, Bastian Venthur, and Nis Martensen.
piuparts.debian.org switch to python3 done. Many thanks to all who contributed: Herbert Parentes Fortes Neto, Thomas Goirand, Mattia Rizzolo, Holger Levsen, Bastian Venthur, Nis Martensen and James Clarke.
</td>
</tr>
<tr class="normalrow">
......
......@@ -1560,7 +1560,7 @@ class Section:
md5cachefile = os.path.join(self._output_directory, '.md5cache')
try:
with open(md5cachefile, "rb") as f:
self._md5cache['old'] = pickle.load(f)
self._md5cache['old'] = pickle.load(f, encoding='utf-8')
except (IOError, EOFError):
pass
......
......@@ -2051,8 +2051,8 @@ def diff_meta_data(tree1, tree2, quiet=False):
del tree1_c[name]
del tree2_c[name]
removed = [x for x in six.iteritems(tree1)]
new = [x for x in six.iteritems(tree2)]
removed = [x for x in six.iteritems(tree1_c)]
new = [x for x in six.iteritems(tree2_c)]
# fix for #586793
# prune rc?.d symlinks renamed by insserv
......