Anki Forums

KeyError when syncing older clients

i used to sync my collection each day from my computer but today i tried it it tells me that syncing failed and shows the following massage:

Syncing failed:
Traceback (most recent call last):
File “aqt\sync.py”, line 429, in _sync
File “aqt\sync.py”, line 409, in _abortingSync
File “lib\site-packages\anki\sync.py”, line 137, in sync
File “lib\site-packages\anki\sync.py”, line 219, in sanityCheck
File “lib\site-packages\anki\schedv2.py”, line 68, in reset
File “lib\site-packages\anki\sched.py”, line 556, in _resetRev
File “<C:\Program Files\Anki\decorator.pyc:decorator-gen-24>”, line 2, in _resetRevCount
File “lib\site-packages\anki\hooks.py”, line 666, in decorator_wrapper
File “lib\site-packages\anki\hooks.py”, line 663, in repl
File “C:\Users\bilal\AppData\Roaming\Anki2\addons21\1460733408\hoochieMama.py”, line 169, in resetRevCount
return _old(sched)
File “lib\site-packages\anki\sched.py”, line 553, in _resetRevCount
File “lib\site-packages\anki\schedv2.py”, line 213, in _walkingCount
File “lib\site-packages\anki\decks.py”, line 630, in parents
KeyError: ‘AnKing::Zanki Step Decks::Zanki Hematology & Oncology’

@abdnassar20160885 updating to the latest Anki should make the error go away. You can then rename the problem deck and downgrade again if you wish (note the warning on https://changes.ankiweb.net/#/)

@andrewsanchez This is probably caused by a parent deck with different capitalisation, which newer Anki versions accept but older ones do not. It would be good if this could be fixed in the deck you’re distributing so others don’t have the same issue

2 Likes

This is definitely something we can address in the near future for people who download the deck for the first time and with upcoming updates to the deck as well.

I made a local backup and then created another profile in anki and then restored. That seemed to solve the problem and i was able to sync using the new profile perfectly