I installed the lilypond add-on. I tried to display a card with Anki 2.1.15 and got a bug report. So I updated to Anki 2.1.22, and now lilypond code won’t compile at all – I get the text to show as entered.
I’m on a Win 10 Desktop PC. Lilypond is in my path. Anki 2.0 version of this add-on worked just fine.
Here’s what Anki 2.1.15 said when trying to display lilypond:
Anki 2.1.15 (442df9d6) Python 3.6.7 Qt 5.12.1 PyQt 5.11.3
Platform: Windows 10
Flags: frz=True ao=True sv=1
Caught exception:
File “aqt\progress.py”, line 72, in handler
File “aqt\clayout.py”, line 306, in _renderPreview
File “anki\cards.py”, line 120, in q
File “anki\cards.py”, line 137, in _getQA
File “anki\collection.py”, line 589, in _renderQA
File “anki\hooks.py”, line 39, in runFilter
File “C:\Users\immo\AppData\Roaming\Anki2\addons21\123418104\lilypond.py”, line 243, in mungeFields
match.group(), _imgLink(col, match.group(2), _lyFromHtml(match.group(3)))
File “C:\Users\immo\AppData\Roaming\Anki2\addons21\123418104\lilypond.py”, line 195, in _imgLink
err = _buildImg(col, ly, fname)
File “C:\Users\immo\AppData\Roaming\Anki2\addons21\123418104\lilypond.py”, line 162, in _buildImg
lyfile.write(ly.decode(“utf-8”))
File “C:\Program Files\Python36\lib\encodings\cp1252.py”, line 19, in encode
<class ‘UnicodeEncodeError’>: ‘charmap’ codec can’t encode character ‘\u017c’ in position 366: character maps to