MorphMan for Anki 2.1 doesn't work on latest version (2.1.22)

Colin G's Avatar

Colin G

20 Mar, 2020 05:06 PM

I receive an error whenever I open Anki (2.1.22) with the add-on, "MorphMan for Anki 2.1". It is certainly this add-on that is causing the error because all my other add-ons are working correctly when enabled. When I disable "Morphman for Anki 2.1", Anki works fine.

Caught exception:
Traceback (most recent call last):
  File "aqt\progress.py", line 76, in handler
  File "aqt\main.py", line 158, in setupProfileAfterWebviewsLoaded
  File "aqt\main.py", line 195, in setupProfile
  File "<C:\Program Files\Anki\decorator.pyc:decorator-gen-42>", line 2, in loadProfile
  File "lib\site-packages\anki\hooks.py", line 666, in decorator_wrapper
  File "lib\site-packages\anki\hooks.py", line 661, in repl
  File "aqt\main.py", line 345, in loadProfile
  File "<C:\Program Files\Anki\decorator.pyc:decorator-gen-48>", line 2, in loadCollection
  File "lib\site-packages\anki\hooks.py", line 666, in decorator_wrapper
  File "lib\site-packages\anki\hooks.py", line 657, in repl
  File "<C:\Program Files\Anki\decorator.pyc:decorator-gen-46>", line 2, in loadCollection
  File "lib\site-packages\anki\hooks.py", line 666, in decorator_wrapper
  File "lib\site-packages\anki\hooks.py", line 657, in repl
  File "<C:\Program Files\Anki\decorator.pyc:decorator-gen-44>", line 2, in loadCollection
  File "lib\site-packages\anki\hooks.py", line 666, in decorator_wrapper
  File "lib\site-packages\anki\hooks.py", line 658, in repl
  File "C:\Users\Colin\AppData\Roaming\Anki2\addons21\874215009\advancedbrowser\basic_fields.py", line 75, in myLoadCollection
    mw.col.db._db.create_function("nameForDeck", 1, self.nameForDeck)
AttributeError: 'NoneType' object has no attribute 'db'

  1. 1 Posted by Young on 21 Mar, 2020 01:52 PM

    Young's Avatar

    I seem to have the same problem. Just tried to install the add-on but it doesn't work. Neither does it work on Anki 2.1.23.
    Do you thins this is an anki version problem?

    My debug info is as follows:

    Debug info: Traceback (most recent call last):
    File "aqt/main.py", line 441, in loadCollection File "aqt/main.py", line 467, in _loadCollection File "aqt/main.py", line 588, in moveToState File "aqt/main.py", line 595, in _deckBrowserState File "aqt/deckbrowser.py", line 56, in show File "aqt/toolbar.py", line 48, in draw File "", line 2, in _centerLinks File "anki/hooks.py", line 666, in decorator_wrapper File "anki/hooks.py", line 663, in repl File "/Users/youngchen/Library/Application Support/Anki2/addons21/900801631/morph/stats.py", line 73, in my_centerLinks return self._linkHTML(links) AttributeError: 'Toolbar' object has no attribute '_linkHTML'

  2. 2 Posted by Colin G on 21 Mar, 2020 03:00 PM

    Colin G's Avatar

    I don't know what to think, that's why i'm posting the problem here haha. I do know, however, that the add-on works on 2.1.19. I reverted back to that version and it works fine.

  3. 3 Posted by Young on 21 Mar, 2020 04:30 PM

    Young's Avatar

    Yeah, I just tried 2.1.19 on my MacOS and the add-on works. Sadly this version doesn't work with the latest MIA Dictionary add-on. T T

    Hope either developers might fix this problem.

  4. 4 Posted by Nihongo Master on 31 Mar, 2020 10:38 PM

    Nihongo Master's Avatar

    Go to the following link: https://github.com/kaegi/MorphMan/blob/master/morph/stats.py. copy and paste the text starting at line 1. Then go C:\Users\REPLACEWITHYOURUSER\AppData\Roaming\Anki2\addons21\900801631\morph in windows. click on stats.py and edit with a notpad++ or other text file editor. Then ctrl + a delete everything and paste what you copied from github. Save the file and restart anki. The problem should be fixed.

  5. 5 Posted by Nihongo Master on 31 Mar, 2020 10:39 PM

    Nihongo Master's Avatar

    copy all the text from line 1 - 77 in the github page

  6. 6 Posted by Young on 01 Apr, 2020 04:33 PM

    Young's Avatar

    Yes, it worked well for me. A thousand thx!

  7. 7 Posted by Colin G on 08 Apr, 2020 01:59 AM

    Colin G's Avatar

    Worked for me too. ありがとう

  8. 8 Posted by taif on 04 Jul, 2020 03:54 AM

    taif's Avatar

    worked for me too, thank you very much

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

Keyboard shortcuts

Generic

? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac