infstellar / genshin_impact_assistant

原神小助手 Genshin Assistant (CN/EN) | 自动战斗,秘境,领日常,半自动委托
GNU Affero General Public License v3.0
2.73k stars 223 forks source link

MissionPage crashes when non-standard mission is installed #198

Open zaunfink opened 2 months ago

zaunfink commented 2 months ago

I'm using giaglobal.json.

When I install any mission via MissionDownloadPage and attempt to view the missions via MissionPage, I get an internal error.

js: Error(%s) in dispatch command: %s TypeError: Cannot read property 'update_input' of undefined pin_update js: Error(%s) in dispatch command: %s TypeError: Cannot read property 'update_input' of undefined pin_update js: Error(%s) in dispatch command: %s TypeError: Cannot read property 'update_input' of undefined pin_update D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\installed_python\3.7.6_GIA_Launcher_Download_Lib\lib\site-packages\urllib3\connectionpool.py:1071: InsecureRequestWarning: Unverified HTTPS request is being made to host 'raw.githubusercontent.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings InsecureRequestWarning, D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\installed_python\3.7.6_GIA_Launcher_Download_Lib\lib\site-packages\urllib3\connectionpool.py:1071: InsecureRequestWarning: Unverified HTTPS request is being made to host 'github.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings InsecureRequestWarning, D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\installed_python\3.7.6_GIA_Launcher_Download_Lib\lib\site-packages\urllib3\connectionpool.py:1071: InsecureRequestWarning: Unverified HTTPS request is being made to host 'raw.githubusercontent.com'. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/1.26.x/advanced-usage.html#ssl-warnings InsecureRequestWarning, js: Error(%s) in dispatch command: %s TypeError: Cannot read property 'update_input' of undefined pin_update Unhandled error in pywebio app Traceback (most recent call last): File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\installed_python\3.7.6_GIA_Launcher_Download_Lib\lib\site-packages\pywebio\session\threadbased.py", line 261, in run callback(event['data']) File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\installed_python\3.7.6_GIA_Launcher_Download_Lib\lib\site-packages\pywebio\output.py", line 843, in click_callback return onclick(btn_val) File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\repositories\GIA_Launcher_Download_Lib\source\webio\page_manager.py", line 24, in load_page self.page_dict[idx].load() File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\repositories\GIA_Launcher_Download_Lib\source\webio\page.py", line 17, in load self._on_load() File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\repositories\GIA_Launcher_Download_Lib\source\webio\advance_page.py", line 39, in _on_load super()._on_load() File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\repositories\GIA_Launcher_Download_Lib\source\webio\page.py", line 27, in _on_load self._load() # 加载主页 File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\repositories\GIA_Launcher_Download_Lib\source\webio\webpages\mission.py", line 222, in _load self._render_scopes() File "D:\Downloads\PGPLC-0.5.1\python-git-program-launcher\repositories\GIA_Launcher_Download_Lib\source\webio\webpages\mission.py", line 107, in _render_scopes if GLOBAL_LANG in self.MISSION_META[mission_name]['title']: TypeError: argument of type 'NoneType' is not iterable

infstellar commented 2 months ago

thanks for your issue. I'm sorry for the lack of support for English at present. I will try my best to make up the English support next week.

infstellar commented 2 months ago

I tried to fix the bug. is it works?

zaunfink commented 2 months ago

Thank you for your fast response! I can now add the mission and the list compiles correctly, but the entry has no title and shows this error in the console:

2024-09-05 19:18:45.094 | ERROR | source.webio.webpages.mission:_render_scopes:112 - mission GIA_SangoPearl_1 has not title?

infstellar commented 1 month ago

This may be because there is no English text in the title of mission, I will try to fix it.

infstellar commented 1 month ago

This bug has been fixed and had tested on my computer :)