-
Notifications
You must be signed in to change notification settings - Fork 1
Description
想问下老师这个应该怎么处理
————————————————————————————————————————————————————
{'date': '2024-07-05', 'week': '五', 'war': '英雄江天夜宴', 'battle': '神农洇', 'orecar': '烂柯山', 'school': '纯阳·西昇大典', 'rescue': '少林·乱世', 'luck': ['一杠', '财财', '枫林客'], 'card': ['英雄罗汉门', '英雄剑冢惊变', '达摩洞'], 'leader': ['岑伤', '森九岚'], 'draw': '长歌·正太[琢诗]', 'team': ['经首道源·越海珠贝;龙泉府·雪国冬猎', '英雄梧桐山庄;英雄梦入集真岛;英雄剑冢惊变', '冷龙峰;范阳夜变;敖龙岛']}
Traceback (most recent call last):
File "D:\Project\test\test_jx3_api\test.py", line 11, in
api.data_active_calendar(server="梦江南")
File "d:\Project\nonebot2.conda\lib\site-packages\jx3apifun\http\handler.py", line 49, in wrapper
return caller.call_api_sync(request, model)
File "d:\Project\nonebot2.conda\lib\site-packages\jx3apifun\http\caller.py", line 63, in call_api_sync
return convert(data, model, strict=False)
msgspec.ValidationError: Expected str | null, got array - at $.leader
————————————————————————————————————————————————————
{'date': '2024-07-06', 'week': '六', 'war': '英雄幽藤馆', 'battle': '三国古战场', 'orecar': '烂柯山', 'school': '纯
阳·西昇大典', 'rescue': '万花·乱世', 'luck': ['红绸', '刀豆', '鸿鸿'], 'card': ['英雄集真岛', '英雄梧桐山庄', '白帝 江关'], 'draw': '长歌·萝莉[挽琴]', 'team': ['经首道源·越海珠贝;龙泉府·雪国冬猎', '英雄梧桐山庄;英雄梦入集真岛;英雄剑冢惊变', '冷龙峰;范阳夜变;敖龙岛']}
result:DataActiveCalendar(date='2024-07-06', week='六', war='英雄幽藤馆', battle='三国古战场', orecar='烂柯山', leader=None, school='纯阳·西昇大典', rescue='万花·乱世', draw='长歌·萝莉[挽琴]', luck=['红绸', '刀豆', '鸿鸿'], card=['英雄集真岛', '英雄梧桐山庄', '白帝江关'])
—————————————————————————————————————————————————————