Unlucky-Life/ankimon

Ankimon not loading when I open Anki

Closed this issue · 4 comments

Anki 24.04.1 (ccd9ca1a) (ao)
Python 3.9.18 Qt 6.6.2 PyQt 6.6.1
Platform: Windows-10-10.0.22631

When loading Ankimon by Unlucky-life:
Traceback (most recent call last):
File "C:\Users\thecw\AppData\Roaming\Anki2\addons21\1908235722_init_.py", line 1132, in generate_random_pokemon
base_experience = search_pokeapi_db_by_id(id, "base_experience")
File "C:\Users\thecw\AppData\Roaming\Anki2\addons21\1908235722_init_.py", line 1993, in search_pokeapi_db_by_id
with open(str(pokeapi_db_path), "r", encoding="utf-8") as json_file:
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\thecw\AppData\Roaming\Anki2\addons21\1908235722\user_files\data_files\pokeapi_db.json'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "aqt.addons", line 247, in loadAddons
File "C:\Users\thecw\AppData\Roaming\Anki2\addons21\1908235722_init_.py", line 2050, in
name, id, level, ability, type, stats, enemy_attacks, base_experience, growth_rate, hp, max_hp, ev, iv, gender, battle_status, battle_stats = generate_random_pokemon()
File "C:\Users\thecw\AppData\Roaming\Anki2\addons21\1908235722_init_.py", line 1166, in generate_random_pokemon
showInfo("Error", "Can't open the JSON File.")
File "aqt.utils", line 296, in showInfo
TypeError: arguments did not match any overloaded call:
QMessageBox(parent: Optional[QWidget] = None): argument 1 has unexpected type 'str'
QMessageBox(icon: QMessageBox.Icon, title: Optional[str], text: Optional[str], buttons: QMessageBox.StandardButton = QMessageBox.NoButton, parent: Optional[QWidget] = None, flags: Qt.WindowType = Qt.Dialog|Qt.MSWindowsFixedSizeDialogHint): argument 1 has unexpected type 'str'

@AnkiBiceps
seems to be missing a file:
FileNotFoundError: [Errno 2] No such file or directory: 'C:\Users\thecw\AppData\Roaming\Anki2\addons21\1908235722\user_files\data_files\pokeapi_db.json'

Did you download the files yet withe "Download Resourxes" Button ?
If not or if any issues occured go to this page:

#32
And download the needed files please :)

Hi so I don't even have the Ankimon as a dropdown thing at the top of the screen where I would click that. I just get this window when I start up Anki ---- trying to download the files manually now
image

the download and unzipping files worked!!! THANK YOU!!!!!!!! Love this addon!!!!!!!!!!!!!!!!!!

Weird but now you got it :) have fun !