Your message dated Tue, 08 Dec 2020 20:33:54 +0000 with message-id <e1kmjgi-000cab...@fasolo.debian.org> and subject line Bug#975395: fixed in anki 2.1.15+dfsg-3 has caused the Debian Bug report #975395, regarding anki: Fails with Python3.9 due to use of deprecated unescape() method to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact ow...@bugs.debian.org immediately.) -- 975395: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=975395 Debian Bug Tracking System Contact ow...@bugs.debian.org with problems
--- Begin Message ---Package: anki Version: 2.1.15+dfsg-2 Severity: normal Tags: patch Hello, since the update to python3.9 Anki fails with the following exception when reviewing more complex HTML templates: <class 'AttributeError'>: 'HTMLParser' object has no attribute 'unescape' The following patch fixes this issue for me: --- /usr/share/anki/aqt/reviewer.py.orig 2019-08-27 07:24:40.000000000 +0200 +++ /usr/share/anki/aqt/reviewer.py 2020-11-21 16:49:53.517798570 +0100 @@ -353,13 +353,12 @@ buf = buf.replace("<hr id=answer>", "") hadHR = len(buf) != origSize # munge correct value - parser = html.parser.HTMLParser() cor = self.mw.col.media.strip(self.typeCorrect) cor = re.sub("(\n|<br ?/?>|</?div>)+", " ", cor) cor = stripHTML(cor) # ensure we don't chomp multiple whitespace cor = cor.replace(" ", " ") - cor = parser.unescape(cor) + cor = html.parser.unescape(cor) cor = cor.replace("\xa0", " ") cor = cor.strip() given = self.typedAnswer It looks like unescape() was never intended to be exposed via the HTMLParser() object. But since Python 3.4 html.parser provides it directly. Regards Simon -- + privacy is necessary + using gnupg http://gnupg.org + public key id: 0x92FEFDB7E44C32F9
signature.asc
Description: PGP signature
--- End Message ---
--- Begin Message ---Source: anki Source-Version: 2.1.15+dfsg-3 Done: Julian Gilbey <j...@debian.org> We believe that the bug you reported is fixed in the latest version of anki, which is due to be installed in the Debian FTP archive. A summary of the changes between this version and the previous one is attached. Thank you for reporting the bug, which will now be closed. If you have further comments please address them to 975...@bugs.debian.org, and the maintainer will reopen the bug report if appropriate. Debian distribution maintenance software pp. Julian Gilbey <j...@debian.org> (supplier of updated anki package) (This message was generated automatically at their request; if you believe that there is a problem with it please contact the archive administrators by mailing ftpmas...@ftp-master.debian.org) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 Format: 1.8 Date: Tue, 08 Dec 2020 20:13:39 +0000 Source: anki Architecture: source Version: 2.1.15+dfsg-3 Distribution: unstable Urgency: medium Maintainer: Julian Gilbey <j...@debian.org> Changed-By: Julian Gilbey <j...@debian.org> Closes: 975395 Changes: anki (2.1.15+dfsg-3) unstable; urgency=medium . * Fix html.parser.HTMLParser().unescape() -> html.parser.unescape() for Python 3.9 with thanks to Simon Ruderich <si...@ruderich.org> (closes: #975395) Checksums-Sha1: f821c232006c4224718971d69e116a46964cca31 1838 anki_2.1.15+dfsg-3.dsc 19eb4c377f4c5cc3d1f691055b73169656582197 33260 anki_2.1.15+dfsg-3.debian.tar.xz b88fa668745ea7b24c989015b47f9a61175233ee 7264 anki_2.1.15+dfsg-3_amd64.buildinfo Checksums-Sha256: 8abf30284b90c018e248af445afb2daa1e18ab60fdc7d67353fdfc62fb0ef97b 1838 anki_2.1.15+dfsg-3.dsc cb5040e9af779ff5e5cd0f14392130b188d731fb17c0824f425f2b1cbd5118f3 33260 anki_2.1.15+dfsg-3.debian.tar.xz 9cacc6ddea5c11a9cb0368afd52be38b9dd488d48a9f8a33761d400668d86650 7264 anki_2.1.15+dfsg-3_amd64.buildinfo Files: 7e4c612075c1ed1780090d67890823c1 1838 education optional anki_2.1.15+dfsg-3.dsc aad032ac945b8d399445719bb7d5e69a 33260 education optional anki_2.1.15+dfsg-3.debian.tar.xz 83fac328f84970e832f25d540696a265 7264 education optional anki_2.1.15+dfsg-3_amd64.buildinfo -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEEfhrD+iemSShMMj72aVxCkxbAe/4FAl/P33oACgkQaVxCkxbA e/7CNg/8D2Qk8AtrqztCIf04jNCXUHtM5Gv/3B5/+QlNy/DPCyDlEDTLNrl2OsKX efWycIqAr8qVDxNJuZ6GWStJnqypgJCM6ypq8bHPOs8OW39m34ByXSZaaJ4GQGrd 5d7EnmB0ScY7xJjIuYx2F8KIrLIOrdAbMa3qjQYDjLZ05i/Hq6Mc6Ms+TbbAP1ak E2E5UMcRgJJ7owVgkNB1Q8SsJpsXDamHr0PPkjsm9P7yLxi+SNFLC0RdY6LLH5Pv JEIb0+SIHCnWIxh25NuFCJXa0YmYmhgdlIZO8pvGKSGBLJgYlElVClFfAU5kgm8N FLlO4iwhTsa3eTsutjQVb3xltVa2nNW64x0VJdLYo9xO6RKSCxc0gvWwLgfAOVvY RGLNpHaHm6eYJF0m7+H5iguK0SH54oWO/nc4zYwQ+9c6cXj2dN5Vh8DXFImy81dm ZzM5mWHpDKbTcugChi4DzT20QULDXOa0ckIIj/fvWGHAmj68MQ+sDlI8s3R9JmB7 oG6Ov1SrqoQ+AI3eqK45N5TgclQouPjyn0g02Kg330dblWezi++3pPWML+GtGtWQ c8zSCnKI0seFwmzCmntTvZ/J0zLuqAlVkRSOknQzLOPYH6OGfrsPG0J28dkUW3n1 SlVtKfqB+lKXIU+iAMItHyjoh6Zi4s1pAjp22nkk6mpNCUHxGhs= =WPmo -----END PGP SIGNATURE-----
--- End Message ---