[BUG] Copy debug info button crashes Anki 24.04 and 24.06.3

I can’t see a category for Bug Reports as github’s new issue landing page would suggest.

Anki 24.04 (429bc9e1)  
Python 3.9.18 Qt 6.6.2 PyQt 6.6.1
Platform: macOS-14.7-arm64-arm-64bit

Traceback (most recent call last):
  File "aqt.import_export.exporting", line 114, in accept
  File "aqt.import_export.exporting", line 271, in export
  File "aqt.operations", line 262, in run_in_background
  File "aqt.operations", line 272, in _run
  File "aqt.taskman", line 119, in with_backend_progress
  File "aqt.progress", line 183, in start_with_backend_updates
  File "aqt.progress", line 150, in start
  File "aqt.progress", line 332, in __init__
TypeError: QDialog(parent: Optional[QWidget] = None, flags: Qt.WindowType = Qt.WindowFlags()): argument 1 has unexpected type 'weakproxy'


Anki 24.06.3 (d678e393)  
Python 3.9.18 Qt 6.6.2 PyQt 6.6.1
Platform: macOS-14.7-arm64-arm-64bit

Traceback (most recent call last):
  File "aqt.import_export.exporting", line 114, in accept
  File "aqt.import_export.exporting", line 271, in export
  File "aqt.operations", line 262, in run_in_background
  File "aqt.operations", line 272, in _run
  File "aqt.taskman", line 119, in with_backend_progress
  File "aqt.progress", line 183, in start_with_backend_updates
  File "aqt.progress", line 150, in start
  File "aqt.progress", line 336, in __init__
TypeError: QDialog(parent: Optional[QWidget] = None, flags: Qt.WindowType = Qt.WindowFlags()): argument 1 has unexpected type 'weakproxy'

Generate an empty card scenario

Make a card (either cloze or Basic with reverse). Add content to the reverse side, and then remove it later. Anki will have created a reverse card but it won’t get auto-removed when you remove the content from it. Alternatively, rename {{c2::}} to {{c1::}} so that cloze 2 doesn’t exist, and there’s two cloze 1.

How to reproduce

  1. Start Anki with Shift down to rule out add-on issues.
  2. Tools → Empty Cards…
  3. Click one of the results to open a filtered browser view.
  4. Click Notes → Export Notes. Make any selections you want, but keep .apkg, then hit Export. Give it a name, and then Anki will present the crash dialog.

If you click close, you can continue on your merry way after the failed export attempt. If you click copy debug info, then Anki window no longer respond to clicks or key presses and you have to force quit its process (end task for windows folk, or kill -9 for linux ppl).

Expectation

I would like Anki to not crash when I hit copy debug info.

Thanks for the detailed report; a fix will be in the next build.

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