[Piuparts-devel] [Git][debian/piuparts][develop] 3 commits: Fix diff_meta_data reporting every file as new and removed
Holger Levsen
gitlab at salsa.debian.org
Sun Dec 29 16:27:42 GMT 2019
Holger Levsen pushed to branch develop at Debian / piuparts
Commits:
14c81dc7 by James Clarke at 2019-12-29T16:25:37Z
Fix diff_meta_data reporting every file as new and removed
This regressed in 0b47bf88944065fa5e69b02574317e7b2d189d2a, which
erroneously used the original trees rather than the modified copies.
Signed-off-by: Holger Levsen <holger at layer-acht.org>
- - - - -
b1738ebd by Holger Levsen at 2019-12-29T16:26:44Z
add changelog entry for James
Signed-off-by: Holger Levsen <holger at layer-acht.org>
- - - - -
fda3b882 by Nis Martensen at 2019-12-29T16:27:23Z
piuparts-report: fix pickle.loading str from python2
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: Holger Levsen <holger at layer-acht.org>
- - - - -
4 changed files:
- debian/changelog
- htdocs/news.tpl
- piuparts-report.py
- piuparts.py
Changes:
=====================================
debian/changelog
=====================================
@@ -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 at debian.org> Sun, 07 Jul 2019 17:15:41 +0200
piuparts (1.0.1) unstable; urgency=medium
=====================================
htdocs/news.tpl
=====================================
@@ -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">
=====================================
piuparts-report.py
=====================================
@@ -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
=====================================
piuparts.py
=====================================
@@ -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
View it on GitLab: https://salsa.debian.org/debian/piuparts/compare/2f15d124ddd211ead2380e671a6a8d22d3148f63...fda3b88291469fc46a91edf8aaba689be5ef5ce9
--
View it on GitLab: https://salsa.debian.org/debian/piuparts/compare/2f15d124ddd211ead2380e671a6a8d22d3148f63...fda3b88291469fc46a91edf8aaba689be5ef5ce9
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/piuparts-devel/attachments/20191229/e7dc4299/attachment-0001.html>
More information about the Piuparts-devel
mailing list