Skip to content

Commit

Permalink
fix: use max compat pydanic; style fix
Browse files Browse the repository at this point in the history
  • Loading branch information
tazlin committed Jul 20, 2024
1 parent e98c30e commit 6845419
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 26 deletions.
5 changes: 3 additions & 2 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,13 @@ repos:
pass_filenames: false
additional_dependencies: [
pytest,
pydantic,
pydantic==2.7.4,
types-Pillow,
types-requests,
types-pytz,
types-setuptools,
types-urllib3,
types-aiofiles,
StrEnum
StrEnum,
horde_model_reference==0.8.1,
]
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
horde_model_reference~=0.7.0
horde_model_reference~=0.8.1

pydantic
pydantic==2.7.4
requests
StrEnum
loguru
Expand Down
22 changes: 1 addition & 21 deletions tests/ai_horde_api/test_ai_worker_roundtrip_api_calls.py
Original file line number Diff line number Diff line change
@@ -1,47 +1,27 @@
import asyncio
import base64
from typing import Any

import aiohttp
import PIL.Image
import pytest
from loguru import logger
import yarl
from loguru import logger

from horde_sdk.ai_horde_api.ai_horde_clients import (
AIHordeAPIAsyncClientSession,
AIHordeAPIAsyncSimpleClient,
AIHordeAPISimpleClient,
)
from horde_sdk.ai_horde_api.apimodels import (
KNOWN_ALCHEMY_TYPES,
AlchemyAsyncRequest,
AlchemyAsyncRequestFormItem,
AlchemyStatusResponse,
ImageGenerateAsyncRequest,
ImageGenerateAsyncResponse,
ImageGenerateCheckResponse,
ImageGenerateJobPopPayload,
ImageGenerateJobPopRequest,
ImageGenerateJobPopResponse,
ImageGenerateJobPopSkippedStatus,
ImageGenerateStatusResponse,
ImageGenerationInputPayload,
ImageGenerationJobSubmitRequest,
JobSubmitResponse,
LorasPayloadEntry,
)
from horde_sdk.ai_horde_api.apimodels.base import ExtraSourceImageEntry
from horde_sdk.ai_horde_api.consts import (
GENERATION_STATE,
KNOWN_FACEFIXERS,
KNOWN_MISC_POST_PROCESSORS,
KNOWN_SOURCE_PROCESSING,
KNOWN_UPSCALERS,
POST_PROCESSOR_ORDER_TYPE,
)
from horde_sdk.ai_horde_api.fields import JobID
from horde_sdk.generic_api.apimodels import RequestErrorResponse


class TestImageWorkerRoundtrip:
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
import os
import pathlib

from loguru import logger
import pytest
from loguru import logger

os.environ["TESTS_ONGOING"] = "1"

Expand Down

0 comments on commit 6845419

Please sign in to comment.