diff --git a/src/api/v1/report.py b/src/api/v1/report.py index 7ed7dea..a955a06 100644 --- a/src/api/v1/report.py +++ b/src/api/v1/report.py @@ -98,15 +98,15 @@ async def parse_detection(data: dict) -> dict: class equipment(BaseModel): - equip_head_id: int = Field(None, ge=0) - equip_amulet_id: int = Field(None, ge=0) - equip_torso_id: int = Field(None, ge=0) - equip_legs_id: int = Field(None, ge=0) - equip_boots_id: int = Field(None, ge=0) - equip_cape_id: int = Field(None, ge=0) - equip_hands_id: int = Field(None, ge=0) - equip_weapon_id: int = Field(None, ge=0) - equip_shield_id: int = Field(None, ge=0) + equip_head_id: int = Field(0, ge=0) + equip_amulet_id: int = Field(0, ge=0) + equip_torso_id: int = Field(0, ge=0) + equip_legs_id: int = Field(0, ge=0) + equip_boots_id: int = Field(0, ge=0) + equip_cape_id: int = Field(0, ge=0) + equip_hands_id: int = Field(0, ge=0) + equip_weapon_id: int = Field(0, ge=0) + equip_shield_id: int = Field(0, ge=0) class detection(BaseModel): diff --git a/src/core/config.py b/src/core/config.py index e88d39f..e6d002c 100644 --- a/src/core/config.py +++ b/src/core/config.py @@ -52,10 +52,11 @@ logging.getLogger("asyncmy").setLevel(logging.ERROR) logging.getLogger("aiokafka").setLevel(logging.WARNING) -uvicorn_error = logging.getLogger("uvicorn.error") -uvicorn_error.disabled = True -uvicorn_access = logging.getLogger("uvicorn.access") -uvicorn_access.disabled = True +if env != "DEV": + uvicorn_error = logging.getLogger("uvicorn.error") + uvicorn_error.disabled = True + uvicorn_access = logging.getLogger("uvicorn.access") + uvicorn_access.disabled = True # https://github.com/aio-libs/aiomysql/issues/103 # https://github.com/coleifer/peewee/issues/2229