Windows console error: "Uncaught TypeError: Cannot read properties of null (reading 'style')"

Hey all. There’s an error that gets spitted into the console when resizing the window while either previewing or reviewing the card.

Uncaught TypeError: Cannot read properties of null (reading 'style')
    at Ar (reviewer.js:7:112035)

As a minimum viable example, change the Basic card type (front) to the following, add a card, review the card and resize the window.

{{Front}}

<div id="error_display"></div>

<script>
(() => {

window.onerror = function(a,b,c,d,e) {
  document.getElementById("error_display").innerHTML = e.stack;
}
})();
</script>

This was tested with all addons disabled, on Windows, and with the following version of Anki:

Version <U+2068>2.1.61 (0c1eaf4c)<U+2069>
Python 3.9.15 Qt 6.4.2 PyQt 6.4.0

Note that I wasn’t able to reproduce the issue on Linux (Ubuntu), so this seems like a Windows only issue? Additionally, outside of simply having an error message, I can’t seem to find any actual usage problems after the error pops up, so I’m guessing this will be a very low priority issue.

Quick update: It seems like at least three other people got the same error, two of which were able to reproduce it similarly to the steps indicated.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.