Skip to content

Commit

Permalink
Move AnnotatedInstance to web_poet.annotated.
Browse files Browse the repository at this point in the history
  • Loading branch information
wRAR committed Mar 4, 2024
1 parent 807fbbb commit 2aff81d
Show file tree
Hide file tree
Showing 7 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion tests/test_serialization.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
Stats,
WebPage,
)
from web_poet.page_inputs.annotated import AnnotatedInstance
from web_poet.annotated import AnnotatedInstance
from web_poet.page_inputs.url import _Url
from web_poet.serialization import (
SerializedDataFileStorage,
Expand Down
2 changes: 1 addition & 1 deletion tests/test_testing.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
from zyte_common_items import Item, Metadata, Product

from web_poet import HttpClient, HttpRequest, HttpResponse, WebPage, field
from web_poet.annotated import AnnotatedInstance
from web_poet.exceptions import HttpRequestError, HttpResponseError, Retry, UseFallback
from web_poet.page_inputs import AnnotatedInstance
from web_poet.page_inputs.client import _SavedResponseData
from web_poet.testing import Fixture
from web_poet.testing.__main__ import main as cli_main
Expand Down
1 change: 0 additions & 1 deletion web_poet/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from .fields import field, item_from_fields, item_from_fields_sync
from .page_inputs import (
AnnotatedInstance,
AnyResponse,
BrowserHtml,
BrowserResponse,
Expand Down
File renamed without changes.
1 change: 0 additions & 1 deletion web_poet/page_inputs/__init__.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
from .annotated import AnnotatedInstance
from .browser import BrowserHtml, BrowserResponse
from .client import HttpClient
from .http import (
Expand Down
3 changes: 2 additions & 1 deletion web_poet/serialization/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@
from andi.typeutils import strip_annotated

import web_poet
from web_poet import AnnotatedInstance, Injectable
from web_poet import Injectable
from web_poet.annotated import AnnotatedInstance
from web_poet.pages import is_injectable
from web_poet.utils import get_fq_class_name

Expand Down
2 changes: 1 addition & 1 deletion web_poet/serialization/functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
from typing import Any, Dict, List, Optional, Type, cast

from .. import (
AnnotatedInstance,
HttpClient,
HttpRequest,
HttpRequestBody,
Expand All @@ -11,6 +10,7 @@
PageParams,
Stats,
)
from ..annotated import AnnotatedInstance
from ..exceptions import HttpError
from ..page_inputs.client import _SavedResponseData
from ..page_inputs.url import _Url
Expand Down

0 comments on commit 2aff81d

Please sign in to comment.