.env里只有最小配置toker
使用 Python: E:\BOT\nonebot\b.venv\Scripts\python.exe
04-16 14:40:39 [SUCCESS] nonebot | NoneBot is initializing...
04-16 14:40:39 [INFO] nonebot | Current Env: prod
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_apscheduler"
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_session"
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_saa"
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "ssttkkl_nonebot_utils"
04-16 14:40:40 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_access_control_api"
04-16 14:40:40 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_localstore"
04-16 14:40:40 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_orm"
04-16 14:40:40 [INFO] nonebot_plugin_access_control | use inmemory rate_limit_token storage
04-16 14:40:41 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_access_control"
04-16 14:40:41 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_session_orm"
04-16 14:40:41 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_session_saa"
04-16 14:40:41 [INFO] nonebot_plugin_pixivbot | local cache: enabled (file)
04-16 14:40:42 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_pixivbot"
04-16 14:40:42 [SUCCESS] nonebot | Running NoneBot...
04-16 14:40:42 [INFO] uvicorn | Started server process [27164]
04-16 14:40:42 [INFO] uvicorn | Waiting for application startup.
04-16 14:40:42 [INFO] nonebot_plugin_apscheduler | Scheduler Started
04-16 14:40:42 [ERROR] uvicorn | Traceback (most recent call last):
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 251, in _catch_revision_errors
yield
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 314, in get_revisions
self.revision_map.getrevisions(id),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 543, in get_revisions
return sum([self.get_revisions(id_elem) for idelem in id], ())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 543, in
return sum([self.get_revisions(id_elem) for idelem in id], ())
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 566, in get_revisions
return tuple(
^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 567, in
self._revision_for_ident(rev_id, branch_label)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 638, in _revision_for_ident
raise ResolutionError(
alembic.script.revision.ResolutionError: No such revision or branch '46327b837dd8'
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "E:\BOT\nonebot\b.venv\Lib\site-packages\starlette\routing.py", line 732, in lifespan
async with self.lifespan_context(app) as maybe_state:
File "C:\Users\xiuzh\AppData\Local\Programs\Python\Python311\Lib\contextlib.py", line 204, in aenter
return await anext(self.gen)
^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot\drivers\fastapi.py", line 153, in _lifespan_manager
await self._lifespan.startup()
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot\internal\driver_lifespan.py", line 41, in startup
await self._run_lifespan_func(self._startup_funcs)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot\internal\driver_lifespan.py", line 35, in _run_lifespan_func
await cast(ASYNC_LIFESPAN_FUNC, func)()
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm__init.py", line 84, in init_orm
await greenlet_spawn(migrate.check, alembic_config)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 201, in greenlet_spawn
result = context.throw(*sys.exc_info())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\migrate.py", line 534, in check
script.run_env()
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 583, in run_env
util.load_python_file(self.dir, "env.py")
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\util\pyfiles.py", line 95, in load_python_file
module = load_module_py(module_id, path)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\util\pyfiles.py", line 113, in load_module_py
spec.loader.exec_module(module) # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "", line 940, in exec_module
File "", line 241, in _call_with_frames_removed
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\templates\generic\env.py", line 90, in
await_only(coro)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 131, in await_only
return current.driver.switch(awaitable) # type: ignore[no-any-return]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 196, in greenlet_spawn
value = await result
^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\templates\generic\env.py", line 79, in run_migrations_online
await connection.run_sync(do_run_migrations)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\ext\asyncio\engine.py", line 886, in run_sync
return await greenlet_spawn(
^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 203, in greenlet_spawn
result = context.switch(value)
^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\templates\generic\env.py", line 69, in do_run_migrations
context.run_migrations()
File "", line 8, in run_migrations
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\runtime\environment.py", line 948, in run_migrations
self.get_context().run_migrations(**kw)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\runtime\migration.py", line 615, in run_migrations
for step in self._migrations_fn(heads, self):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\migrate.py", line 521, in retrieve_migrations
if set(script.get_revisions(rev)) != set(script.get_revisions("heads")):
^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 311, in get_revisions
with self._catch_revision_errors():
File "C:\Users\xiuzh\AppData\Local\Programs\Python\Python311\Lib\contextlib.py", line 155, in exit__
self.gen.throw(typ, value, traceback)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 283, in _catch_revision_errors
raise util.CommandError(resolution) from re
alembic.util.exc.CommandError: Can't locate revision identified by '46327b837dd8'
.env里只有最小配置toker
使用 Python: E:\BOT\nonebot\b.venv\Scripts\python.exe
04-16 14:40:39 [SUCCESS] nonebot | NoneBot is initializing...
04-16 14:40:39 [INFO] nonebot | Current Env: prod
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_apscheduler"
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_session"
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_saa"
04-16 14:40:39 [SUCCESS] nonebot | Succeeded to load plugin "ssttkkl_nonebot_utils"
04-16 14:40:40 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_access_control_api"
04-16 14:40:40 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_localstore"
04-16 14:40:40 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_orm"
04-16 14:40:40 [INFO] nonebot_plugin_access_control | use inmemory rate_limit_token storage
04-16 14:40:41 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_access_control"
04-16 14:40:41 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_session_orm"
04-16 14:40:41 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_session_saa"
04-16 14:40:41 [INFO] nonebot_plugin_pixivbot | local cache: enabled (file)
04-16 14:40:42 [SUCCESS] nonebot | Succeeded to load plugin "nonebot_plugin_pixivbot"
04-16 14:40:42 [SUCCESS] nonebot | Running NoneBot...
04-16 14:40:42 [INFO] uvicorn | Started server process [27164]
04-16 14:40:42 [INFO] uvicorn | Waiting for application startup.
04-16 14:40:42 [INFO] nonebot_plugin_apscheduler | Scheduler Started
04-16 14:40:42 [ERROR] uvicorn | Traceback (most recent call last):
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 251, in _catch_revision_errors
yield
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 314, in get_revisions
self.revision_map.getrevisions(id),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 543, in get_revisions
return sum([self.get_revisions(id_elem) for idelem in id], ())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 543, in
return sum([self.get_revisions(id_elem) for idelem in id], ())
^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 566, in get_revisions
return tuple(
^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 567, in
self._revision_for_ident(rev_id, branch_label)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\revision.py", line 638, in _revision_for_ident
raise ResolutionError(
alembic.script.revision.ResolutionError: No such revision or branch '46327b837dd8'
The above exception was the direct cause of the following exception:
Traceback (most recent call last): File "E:\BOT\nonebot\b.venv\Lib\site-packages\starlette\routing.py", line 732, in lifespan async with self.lifespan_context(app) as maybe_state: File "C:\Users\xiuzh\AppData\Local\Programs\Python\Python311\Lib\contextlib.py", line 204, in aenter return await anext(self.gen) ^^^^^^^^^^^^^^^^^^^^^ File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot\drivers\fastapi.py", line 153, in _lifespan_manager await self._lifespan.startup() File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot\internal\driver_lifespan.py", line 41, in startup await self._run_lifespan_func(self._startup_funcs) File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot\internal\driver_lifespan.py", line 35, in _run_lifespan_func await cast(ASYNC_LIFESPAN_FUNC, func)() File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm__init.py", line 84, in init_orm await greenlet_spawn(migrate.check, alembic_config) File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 201, in greenlet_spawn result = context.throw(*sys.exc_info()) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\migrate.py", line 534, in check script.run_env() File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 583, in run_env util.load_python_file(self.dir, "env.py") File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\util\pyfiles.py", line 95, in load_python_file module = load_module_py(module_id, path) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\util\pyfiles.py", line 113, in load_module_py spec.loader.exec_module(module) # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "", line 940, in exec_module
File "", line 241, in _call_with_frames_removed
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\templates\generic\env.py", line 90, in
await_only(coro)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 131, in await_only
return current.driver.switch(awaitable) # type: ignore[no-any-return]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 196, in greenlet_spawn
value = await result
^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\templates\generic\env.py", line 79, in run_migrations_online
await connection.run_sync(do_run_migrations)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\ext\asyncio\engine.py", line 886, in run_sync
return await greenlet_spawn(
^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\sqlalchemy\util_concurrency_py3k.py", line 203, in greenlet_spawn
result = context.switch(value)
^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\templates\generic\env.py", line 69, in do_run_migrations
context.run_migrations()
File "", line 8, in run_migrations
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\runtime\environment.py", line 948, in run_migrations
self.get_context().run_migrations(**kw)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\runtime\migration.py", line 615, in run_migrations
for step in self._migrations_fn(heads, self):
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\nonebot_plugin_orm\migrate.py", line 521, in retrieve_migrations
if set(script.get_revisions(rev)) != set(script.get_revisions("heads")):
^^^^^^^^^^^^^^^^^^^^^^^^^
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 311, in get_revisions
with self._catch_revision_errors():
File "C:\Users\xiuzh\AppData\Local\Programs\Python\Python311\Lib\contextlib.py", line 155, in exit__
self.gen.throw(typ, value, traceback)
File "E:\BOT\nonebot\b.venv\Lib\site-packages\alembic\script\base.py", line 283, in _catch_revision_errors
raise util.CommandError(resolution) from re
alembic.util.exc.CommandError: Can't locate revision identified by '46327b837dd8'