mirror of
https://git.datalinker.icu/comfyanonymous/ComfyUI
synced 2026-09-08 15:37:08 +08:00
fix ruff
This commit is contained in:
parent
cf209aa456
commit
6fb5bb1431
@ -6,10 +6,10 @@ from __future__ import annotations
|
||||
|
||||
from datetime import datetime
|
||||
from enum import Enum
|
||||
from typing import Any, Dict, List, Literal, Optional, Union
|
||||
from typing import Any, Dict, List, Optional, Union
|
||||
from uuid import UUID
|
||||
|
||||
from pydantic import AnyUrl, BaseModel, Field, RootModel, confloat, conint, constr
|
||||
from pydantic import AnyUrl, BaseModel, Field, confloat, conint
|
||||
|
||||
class ComfyNode(BaseModel):
|
||||
category: Optional[str] = Field(
|
||||
|
||||
@ -46,7 +46,7 @@ def validate_and_cast_response (response):
|
||||
if b64_data:
|
||||
img_data = base64.b64decode(b64_data)
|
||||
img = Image.open(io.BytesIO(img_data))
|
||||
|
||||
|
||||
elif image_url:
|
||||
img_response = requests.get(image_url)
|
||||
if img_response.status_code != 200:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user