po-lan / zhenxun_plugins_TZseries

我个人开发或进行魔改的zhenxun插件
12 stars 8 forks source link

TZggl: TypeError expected Q objects as args #49

Closed gili-gili closed 1 year ago

gili-gili commented 1 year ago

Log

00-00 00:00:00 [ERROR] nonebot | Running Matcher(type='message', module=extensive_plugin.zhenxun_plugins_TZseries.TZggl) failed.
Traceback (most recent call last):
  File "/USER_HOME_DIR/zhenxun_bot_v0167/bot.py", line 21, in <module>
    nonebot.run()
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/nonebot/__init__.py", line 273, in run
    get_driver().run(*args, **kwargs)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/nonebot/drivers/fastapi.py", line 172, in run
    uvicorn.run(
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/uvicorn/main.py", line 569, in run
    server.run()
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/uvicorn/server.py", line 60, in run
    return asyncio.run(self.serve(sockets=sockets))
  File "/usr/lib/python3.11/asyncio/runners.py", line 190, in run
    return runner.run(main)
  File "/usr/lib/python3.11/asyncio/runners.py", line 118, in run
    return self._loop.run_until_complete(task)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/nonebot/message.py", line 142, in _check_matcher
    await _run_matcher(Matcher, bot, event, state, stack, dependency_cache)
> File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/nonebot/message.py", line 188, in _run_matcher
    await matcher.run(bot, event, state, stack, dependency_cache)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/nonebot/internal/matcher/matcher.py", line 727, in run
    await self.simple_run(bot, event, state, stack, dependency_cache)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/nonebot/internal/matcher/matcher.py", line 702, in simple_run
    await handler(
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/nonebot/dependencies/__init__.py", line 108, in __call__
    return await cast(Callable[..., Awaitable[R]], self.call)(**values)
  File "/USER_HOME_DIR/zhenxun_bot_v0167/extensive_plugin/zhenxun_plugins_TZseries/TZggl.py", line 89, in _
    allLotteryGold = await TZtreasury.get(gid) + int(cost * 0.7)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/tortoise/models.py", line 1303, in get
    return cls._meta.manager.get_queryset().using_db(db).get(*args, **kwargs)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/tortoise/queryset.py", line 684, in get
    queryset = self.filter(*args, **kwargs)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/tortoise/queryset.py", line 387, in filter
    return self._filter_or_exclude(negate=False, *args, **kwargs)
  File "/USER_HOME_DIR/.cache/pypoetry/virtualenvs/zhenxun-bot-RANDOMTEXT-py3.11/lib/python3.11/site-packages/tortoise/queryset.py", line 363, in _filter_or_exclude
    raise TypeError("expected Q objects as args")
TypeError: expected Q objects as args
Ra2-IFV commented 1 year ago

50