Anki is a smart spaced repetition flashcard program
Find a file
evandrocoan f78166cda2 Fixed previewer.py::render_card() being called twice in row
Related to: https://github.com/ankitects/anki/pull 529
Ensuring "setNote" is called only once during changing of note type

After debugging the code, every time the cards changes, there are
two stacktraces generated and triggered when note cards change:

calling 1590591251.4621403
   File "qt/runanki", line 4, in <module>
  File "F:\anki\qt\aqt\__init__.py", line 365, in run
    _run()
  File "F:\anki\qt\aqt\__init__.py", line 515, in _run
    app.exec()
  File "F:\anki\qt\aqt\webview.py", line 467, in handler
    cb(val)
  File "F:\anki\qt\aqt\editor.py", line 477, in <lambda>
    self.web.evalWithCallback("saveNow(%d)" % keepFocus, lambda res: callback())
  File "F:\anki\qt\aqt\browser.py", line 858, in <lambda>
    self.editor.saveNow(lambda: self._onRowChanged(current, previous))
  File "F:\anki\qt\aqt\browser.py", line 880, in _onRowChanged
    self._renderPreview(True)
  File "F:\anki\qt\aqt\browser.py", line 1576, in _renderPreview
    self._previewer.render_card(cardChanged)
  File "F:\anki\qt\aqt\previewer.py", line 136, in render_card
    print('calling', time.time(), "\n", "".join( traceback.format_stack() ) )

calling 1590591251.4766161
   File "qt/runanki", line 4, in <module>
  File "F:\anki\qt\aqt\__init__.py", line 365, in run
    _run()
  File "F:\anki\qt\aqt\__init__.py", line 515, in _run
    app.exec()
  File "F:\anki\qt\aqt\webview.py", line 467, in handler
    cb(val)
  File "F:\anki\qt\aqt\editor.py", line 453, in oncallback
    gui_hooks.editor_did_load_note(self)
  File "F:\anki\qt\aqt\gui_hooks.py", line 1168, in __call__
    hook(editor)
  File "F:\anki\qt\aqt\browser.py", line 887, in onLoadNote
    self.refreshCurrentCard(editor.note)
  File "F:\anki\qt\aqt\browser.py", line 884, in refreshCurrentCard
    self._renderPreview(False)
  File "F:\anki\qt\aqt\browser.py", line 1576, in _renderPreview
    self._previewer.render_card(cardChanged)
  File "F:\anki\qt\aqt\previewer.py", line 136, in render_card
    print('calling', time.time(), "\n", "".join( traceback.format_stack() ) )
2020-05-27 14:41:07 -03:00
.github Fix misspelling of rsync variable name on checks.yml 2020-05-20 19:19:36 -03:00
meta bump version 2020-05-18 12:50:20 +10:00
proto move dupe check to backend 2020-05-24 19:48:56 +10:00
pylib fix typechecking breaking with latest mypy_protobuf 2020-05-27 09:14:02 +10:00
qt Fixed previewer.py::render_card() being called twice in row 2020-05-27 14:41:07 -03:00
rslib move dupe check to backend 2020-05-24 19:48:56 +10:00
rspy move dupe check to backend 2020-05-24 19:48:56 +10:00
scripts vendor rename script 2020-04-14 19:49:07 +10:00
.gitattributes ftl git attributes 2020-03-20 20:33:12 +10:00
.gitignore save profile stats to file instead of generating report 2020-05-16 12:53:01 +10:00
CONTRIBUTORS Add to contributors 2020-05-27 12:05:42 +02:00
LICENSE vendor rename script 2020-04-14 19:49:07 +10:00
Makefile don't install virtualenv 2020-05-24 14:58:41 +02:00
pkgkey.asc add public key for release signing 2018-09-18 10:40:45 +10:00
README.contributing update README.contributing 2020-05-25 15:43:26 +10:00
README.development update readme 2020-05-12 21:13:34 +10:00
README.md add alpha warning 2020-05-18 13:36:51 +10:00
run remove python version debugging from ./run 2020-04-20 11:21:27 +10:00

This repo contains all the code for the computer version of Anki.

⚠️ The master branch is currently in alpha. Please see https://betas.ankiweb.net/#/

If you'd like to try development builds of Anki but don't feel comfortable building the code, please see https://anki.tenderapp.com/discussions/beta-testing

For more information on building, please see README.development.

If you'd like to contribute code, please see README.contributing.