* Serving Quart app ''
* Debug mode: False
* Please use an ASGI server (e.g. Hypercorn) directly in production
[2024-08-14 20:16:01,844 nonebot] INFO: Scheduler started
[2024-08-14 20:16:01,844 maimaiDX] INFO: 正在获取maimai所有曲目信息
[2024-08-14 20:16:32,041 maimaiDX] ERROR: 从diving-fish获取maimaiDX曲目数据超时,正在使用yuzuapi中转获取曲目数据
/usr/local/lib/python3.8/site-packages/nonebot/message.py:58: UserWarning: defining message_preprocessor outside a plugin is deprecated and will not be supported in the future
warnings.warn('defining message_preprocessor outside a plugin is deprecated '
[2024-08-14 20:15:23,217] ERROR in app: Exception
Traceback (most recent call last):
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_music.py", line 222, in get_music_list
music_data = await maiApi.music_data()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 60, in music_data
return await self._request('GET', self.MaiAPI + '/music_data')
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 34, in _request
data = await res.json()
File "/usr/local/lib/python3.8/site-packages/aiohttp/client_reqrep.py", line 1099, in json
await self.read()
File "/usr/local/lib/python3.8/site-packages/aiohttp/client_reqrep.py", line 1037, in read
self._body = await self.content.read()
File "/usr/local/lib/python3.8/site-packages/aiohttp/streams.py", line 375, in read
block = await self.readany()
File "/usr/local/lib/python3.8/site-packages/aiohttp/streams.py", line 397, in readany
await self._wait("readany")
File "/usr/local/lib/python3.8/site-packages/aiohttp/streams.py", line 304, in _wait
await waiter
File "/usr/local/lib/python3.8/site-packages/aiohttp/helpers.py", line 721, in __exit__
raise asyncio.TimeoutError from None
asyncio.exceptions.TimeoutError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/quart/app.py", line 1700, in startup
await self.ensure_async(func)()
File "/HoshinoBot/hoshino/modules/maimaiDX/maimai.py", line 12, in _
await mai.get_music()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_music.py", line 330, in get_music
self.total_list = await get_music_list()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_music.py", line 226, in get_music_list
music_data = await maiApi.transfer_music()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 143, in transfer_music
return await self._request('GET', self.MaiAliasAPI + '/maimaidxmusic')
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 43, in _request
data = (await res.json())['content']
TypeError: list indices must be integers or slices, not str
Traceback (most recent call last):
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_music.py", line 222, in get_music_list
music_data = await maiApi.music_data()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 60, in music_data
return await self._request('GET', self.MaiAPI + '/music_data')
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 34, in _request
data = await res.json()
File "/usr/local/lib/python3.8/site-packages/aiohttp/client_reqrep.py", line 1099, in json
await self.read()
File "/usr/local/lib/python3.8/site-packages/aiohttp/client_reqrep.py", line 1037, in read
self._body = await self.content.read()
File "/usr/local/lib/python3.8/site-packages/aiohttp/streams.py", line 375, in read
block = await self.readany()
File "/usr/local/lib/python3.8/site-packages/aiohttp/streams.py", line 397, in readany
await self._wait("readany")
File "/usr/local/lib/python3.8/site-packages/aiohttp/streams.py", line 304, in _wait
await waiter
File "/usr/local/lib/python3.8/site-packages/aiohttp/helpers.py", line 721, in __exit__
raise asyncio.TimeoutError from None
asyncio.exceptions.TimeoutError
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/lib/python3.8/site-packages/quart/asgi.py", line 320, in __call__
await self.app.startup()
File "/usr/local/lib/python3.8/site-packages/quart/app.py", line 1700, in startup
await self.ensure_async(func)()
File "/HoshinoBot/hoshino/modules/maimaiDX/maimai.py", line 12, in _
await mai.get_music()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_music.py", line 330, in get_music
self.total_list = await get_music_list()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_music.py", line 226, in get_music_list
music_data = await maiApi.transfer_music()
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 143, in transfer_music
return await self._request('GET', self.MaiAliasAPI + '/maimaidxmusic')
File "/HoshinoBot/hoshino/modules/maimaiDX/libraries/maimaidx_api_data.py", line 43, in _request
data = (await res.json())['content']
TypeError: list indices must be integers or slices, not str
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "run.py", line 8, in <module>
bot.run(use_reloader=False, loop=asyncio.get_event_loop())
File "/usr/local/lib/python3.8/site-packages/nonebot/__init__.py", line 63, in run
super().run(host=host, port=port, *args, **kwargs)
File "/usr/local/lib/python3.8/site-packages/aiocqhttp/__init__.py", line 222, in run
self._server_app.run(host=host, port=port, *args, **kwargs)
File "/usr/local/lib/python3.8/site-packages/quart/app.py", line 852, in run
loop.run_until_complete(asyncio.gather(*tasks))
File "/usr/local/lib/python3.8/asyncio/base_events.py", line 616, in run_until_complete
return future.result()
File "/usr/local/lib/python3.8/site-packages/hypercorn/asyncio/__init__.py", line 44, in serve
await worker_serve(
File "/usr/local/lib/python3.8/site-packages/hypercorn/asyncio/run.py", line 88, in worker_serve
raise exception
File "/usr/local/lib/python3.8/site-packages/hypercorn/asyncio/lifespan.py", line 55, in handle_lifespan
await self.app(
File "/usr/local/lib/python3.8/site-packages/hypercorn/app_wrappers.py", line 34, in __call__
await self.app(scope, receive, send)
File "/usr/local/lib/python3.8/site-packages/quart/app.py", line 1667, in __call__
await self.asgi_app(scope, receive, send)
File "/usr/local/lib/python3.8/site-packages/quart/app.py", line 1693, in asgi_app
await asgi_handler(receive, send)
File "/usr/local/lib/python3.8/site-packages/quart/asgi.py", line 322, in __call__
await send(
File "/usr/local/lib/python3.8/site-packages/hypercorn/asyncio/lifespan.py", line 119, in asgi_send
raise LifespanFailureError("startup", message.get("message", ""))
hypercorn.utils.LifespanFailureError: Lifespan failure in startup. 'list indices must be integers or slices, not str'
[2024-08-14 20:15:23,310] ERROR in base_events: Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x7ffa74e1ff70>
[2024-08-14 20:15:23,310] ERROR in base_events: Unclosed connector
connections: ['[(<aiohttp.client_proto.ResponseHandler object at 0x7ffa74e40820>, 189229.165840664)]']
connector: <aiohttp.connector.TCPConnector object at 0x7ffa74e3ce80>
[2024-08-14 20:15:23,310] ERROR in base_events: Unclosed client session
client_session: <aiohttp.client.ClientSession object at 0x7ffa74e3c490>
刚部署完yuzuchan,解决了几个报错后遇到了没法接上数据库的问题,以下是报错信息
顺便想问可以自己搭建本地的数据库吗,要怎么接入呢