Bug#999769: bullseye-pu: package calibre/5.12.0+dfsg-1
Package: release.debian.org
Severity: normal
Tags: bullseye
User: release.debian.org@packages.debian.org
Usertags: pu
X-Debbugs-Cc: yokota.hgml@gmail.com
[ Reason ]
Fix bug #998744 (calibre: Python byte-compile error when installing calibre).
[ Impact ]
Installation fails as describes in bug #998744 .
[ Tests ]
Source code has many unit tests to check high and low level functionality.
[ Risks ]
Change is very trivial.
See "debian/patches/0011-Avoid-to-use-embedded-assignment-syntax-Closes-99874.patch"
.
Not well tested on "bullseye/stable" machine because I use
"sid/unstable" machine.
Trivial checks on my "sid/unstable" machine was OK.
[ Checklist ]
[X] *all* changes are documented in the d/changelog
[X] I reviewed all changes and I approve them
[X] attach debdiff against the package in (old)stable
[X] the issue is verified as fixed in unstable
[ Changes ]
* Avoid to use embedded assignment syntax (Closes: #998744)
[ Other info ]
This fix is already applied on upstream.
This error was also reported at:
https://bugs.launchpad.net/calibre/+bug/1942463
Fixes are:
https://github.com/kovidgoyal/calibre/commit/884839a691e800e56e185e10019a66b12feea640
and
https://github.com/kovidgoyal/calibre/commit/ed32130ca4cbbf235f5560e7c53f78c01eab1106
diff -Nru calibre-5.12.0+dfsg/debian/changelog calibre-5.12.0+dfsg/debian/changelog
--- calibre-5.12.0+dfsg/debian/changelog 2021-02-26 22:39:59.000000000 +0900
+++ calibre-5.12.0+dfsg/debian/changelog 2021-11-16 08:37:45.000000000 +0900
@@ -1,3 +1,9 @@
+calibre (5.12.0+dfsg-1+deb11u1) bullseye; urgency=medium
+
+ * Avoid to use embedded assignment syntax (Closes: #998744)
+
+ -- YOKOTA Hiroshi <yokota.hgml@gmail.com> Tue, 16 Nov 2021 08:37:45 +0900
+
calibre (5.12.0+dfsg-1) unstable; urgency=medium
* New upstream version 5.12.0+dfsg
diff -Nru calibre-5.12.0+dfsg/debian/patches/0011-Avoid-to-use-embedded-assignment-syntax-Closes-99874.patch calibre-5.12.0+dfsg/debian/patches/0011-Avoid-to-use-embedded-assignment-syntax-Closes-99874.patch
--- calibre-5.12.0+dfsg/debian/patches/0011-Avoid-to-use-embedded-assignment-syntax-Closes-99874.patch 1970-01-01 09:00:00.000000000 +0900
+++ calibre-5.12.0+dfsg/debian/patches/0011-Avoid-to-use-embedded-assignment-syntax-Closes-99874.patch 2021-11-16 08:37:45.000000000 +0900
@@ -0,0 +1,31 @@
+From: YOKOTA Hiroshi <yokota.hgml@gmail.com>
+Date: Tue, 9 Nov 2021 23:56:51 +0900
+Subject: Avoid to use embedded assignment syntax (Closes: #998744)
+
+Forwarded: not-needed
+
+This error was also reported at:
+ https://bugs.launchpad.net/calibre/+bug/1942463
+
+Fixes are:
+ https://github.com/kovidgoyal/calibre/commit/884839a691e800e56e185e10019a66b12feea640
+and
+ https://github.com/kovidgoyal/calibre/commit/ed32130ca4cbbf235f5560e7c53f78c01eab1106
+---
+ src/calibre/utils/formatter.py | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/calibre/utils/formatter.py b/src/calibre/utils/formatter.py
+index 83f2a00..18d1afd 100644
+--- a/src/calibre/utils/formatter.py
++++ b/src/calibre/utils/formatter.py
+@@ -656,7 +656,8 @@ class _Interpreter(object):
+
+ def do_node_first_non_empty(self, prog):
+ for expr in prog.expression_list:
+- if v := self.expr(expr):
++ v = self.expr(expr)
++ if v:
+ return v
+ return ''
+
diff -Nru calibre-5.12.0+dfsg/debian/patches/series calibre-5.12.0+dfsg/debian/patches/series
--- calibre-5.12.0+dfsg/debian/patches/series 2021-02-26 22:39:10.000000000 +0900
+++ calibre-5.12.0+dfsg/debian/patches/series 2021-11-16 08:37:45.000000000 +0900
@@ -8,3 +8,4 @@
0008-Don-t-change-book-file-unless-user-s-consent-Closes-.patch
0009-dont-use-python-crypto.patch
0010-Restore-chardet-module-support.patch
+0011-Avoid-to-use-embedded-assignment-syntax-Closes-99874.patch
Reply to: