Hello there! I’m having an issue with Anki not rendering images even when they’re in collection.media.
I’m unable to have images I paste or images I insert via the clipboard button render in the card. It looks like this:
The card HTML has the correct file name of an image in collection.media. I can open the image in an external image viewer, and its filename matches to the one in the card HTML.
The card preview also does not show the image, nor does the card display it when I study the card.
I’m on Anki 2.1.60 on Manjaro Linux (installed from anki-bin in the AUR).
I opened the editor view in the debugger, and I noticed the image wasn’t requested in the Network tab. When I try to open the image address in a new URL (address was http://127.0.0.1:40459/paste-f8fb365a79c18feb2aa09f517d1637c913d39dc3.png, and paste-f8...png does exist in the collection.media folder), I see the following error:
send_file() got an unexpected keyword argument 'max_age'
It looked like a Flask problem of some kind - I looked up the version of Flask currently required by anki and upgraded. Images display now!
For others coming across this issue, upgrading Flask locally to whatever version is listed here should work!