We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7a1ccf9 commit d9206b6Copy full SHA for d9206b6
xiaomusic/cli.py
@@ -183,25 +183,20 @@ def filter(self, record):
183
184
import asyncio
185
186
- from uvicorn import (
187
- Config as UvicornConfig,
188
- )
189
190
- Server,
191
+ import uvicorn
192
193
xiaomusic = XiaoMusic(config)
194
HttpInit(xiaomusic)
195
port = int(config.port)
196
197
# 创建 uvicorn 配置,禁用其信号处理
198
- uvicorn_config = UvicornConfig(
+ uvicorn_config = uvicorn.Config(
199
HttpApp,
200
- host="0.0.0.0",
+ host=["0.0.0.0", "::"],
201
port=port,
202
log_config=LOGGING_CONFIG,
203
)
204
- server = Server(uvicorn_config)
+ server = uvicorn.Server(uvicorn_config)
205
206
# 自定义信号处理
207
shutdown_initiated = False
0 commit comments