Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

导入由genshin-wish-export导出的数据时,报错 #84

Open
nil-err opened this issue Feb 3, 2022 · 7 comments
Open

导入由genshin-wish-export导出的数据时,报错 #84

nil-err opened this issue Feb 3, 2022 · 7 comments

Comments

@nil-err
Copy link

nil-err commented Feb 3, 2022

由genshin-wish-export导出Json,使用UIGF2.1格式导出数据,使用刻记牛杂店导入数据时报错。
image

我自己查看导出的Json数据,发现比较早期的抽卡记录数据时没有id这一个值的

Log如下

keqing-220203.txt

@Scighost
Copy link
Collaborator

Scighost commented Feb 3, 2022

麻烦截个一条记录的图

@nil-err
Copy link
Author

nil-err commented Feb 3, 2022

{"info":{"uid":"*****************","lang":"zh-cn","export_time":1643899733854,"export_app":"genshin-wish-export","export_app_version":"0.8.1","uigf_version":"2.1"},"list":[{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"香菱","item_type":"角色","rank_type":"4","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"菲谢尔","item_type":"角色","rank_type":"4","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"飞天御剑","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"翡玉法球","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"菲谢尔","item_type":"角色","rank_type":"4","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"弹弓","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"冷刃","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"铁影阔剑","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"魔导绪论","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:42:52","name":"以理服人","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"香菱","item_type":"角色","rank_type":"4","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"冷刃","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"沐浴龙血的剑","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"铁影阔剑","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"飞天御剑","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"魔导绪论","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"黑缨枪","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"冷刃","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"冷刃","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:44:29","name":"雨裁","item_type":"武器","rank_type":"4","id":"","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2020-10-02 19:46:20","name":"鸦羽弓","item_type":"武器","rank_type":"3","id":"","uigf_gacha_type":"301"},

@nil-err
Copy link
Author

nil-err commented Feb 3, 2022

这是比较早期没有抽卡id的记录

@nil-err
Copy link
Author

nil-err commented Feb 3, 2022

{"gacha_type":"301","time":"2021-11-02 18:00:43","name":"黑缨枪","item_type":"武器","rank_type":"3","id":"1635847560004909242","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2021-11-02 18:00:49","name":"铁影阔剑","item_type":"武器","rank_type":"3","id":"1635847560005872904","uigf_gacha_type":"301"},{"gacha_type":"301","time":"2021-11-02 18:00:49","name":"黎明神剑","item_type":"武器","rank_type":"3","id":"1635847560005872905","uigf_gacha_type":"301"},

@nil-err
Copy link
Author

nil-err commented Feb 3, 2022

后期有id的记录

@Scighost
Copy link
Collaborator

Scighost commented Feb 3, 2022

有 id 字段但是值为空,会导致转化为int64时出现错误。
先做好备份,然后手动补上0(内容为0的字符串),应该可以解决问题。

(能合并成一条就别分开发,你这一下子给我发了4封通知邮件)

@nil-err
Copy link
Author

nil-err commented Feb 3, 2022

谢谢,打扰到你了很抱歉
你提出的手动补id值的方案是有效的,但是不能补相同值,会被去重。
目前我是自己python处理了一下,能导入了,数据没问题。
但是如果可以的话,还是希望你能考虑在下一版本处理一下这个问题。
谢谢你

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants