Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/crawlee/storage_clients/_file_system/_dataset_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from typing import TYPE_CHECKING, Any

from pydantic import ValidationError
from typing_extensions import override
from typing_extensions import Self, override

from crawlee._consts import METADATA_FILENAME
from crawlee._utils.crypto import crypto_random_object_id
Expand Down Expand Up @@ -94,7 +94,7 @@ async def open(
name: str | None,
alias: str | None,
configuration: Configuration,
) -> FileSystemDatasetClient:
) -> Self:
"""Open or create a file system dataset client.

This method attempts to open an existing dataset from the file system. If a dataset with the specified ID
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from typing import TYPE_CHECKING, Any

from pydantic import ValidationError
from typing_extensions import override
from typing_extensions import Self, override

from crawlee._consts import METADATA_FILENAME
from crawlee._utils.crypto import crypto_random_object_id
Expand Down Expand Up @@ -93,7 +93,7 @@ async def open(
name: str | None,
alias: str | None,
configuration: Configuration,
) -> FileSystemKeyValueStoreClient:
) -> Self:
"""Open or create a file system key-value store client.

This method attempts to open an existing key-value store from the file system. If a KVS with the specified
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
from typing import TYPE_CHECKING

from pydantic import BaseModel, ValidationError
from typing_extensions import override
from typing_extensions import Self, override

from crawlee import Request
from crawlee._consts import METADATA_FILENAME
Expand Down Expand Up @@ -144,7 +144,7 @@ async def open(
name: str | None,
alias: str | None,
configuration: Configuration,
) -> FileSystemRequestQueueClient:
) -> Self:
"""Open or create a file system request queue client.

This method attempts to open an existing request queue from the file system. If a queue with the specified
Expand Down
4 changes: 2 additions & 2 deletions src/crawlee/storage_clients/_memory/_dataset_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from logging import getLogger
from typing import TYPE_CHECKING, Any

from typing_extensions import override
from typing_extensions import Self, override

from crawlee._utils.crypto import crypto_random_object_id
from crawlee._utils.raise_if_too_many_kwargs import raise_if_too_many_kwargs
Expand Down Expand Up @@ -55,7 +55,7 @@ async def open(
id: str | None,
name: str | None,
alias: str | None,
) -> MemoryDatasetClient:
) -> Self:
"""Open or create a new memory dataset client.

This method creates a new in-memory dataset instance. Unlike persistent storage implementations, memory
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from datetime import datetime, timezone
from typing import TYPE_CHECKING, Any

from typing_extensions import override
from typing_extensions import Self, override

from crawlee._utils.crypto import crypto_random_object_id
from crawlee._utils.file import infer_mime_type
Expand Down Expand Up @@ -53,7 +53,7 @@ async def open(
id: str | None,
name: str | None,
alias: str | None,
) -> MemoryKeyValueStoreClient:
) -> Self:
"""Open or create a new memory key-value store client.

This method creates a new in-memory key-value store instance. Unlike persistent storage implementations,
Expand Down
4 changes: 2 additions & 2 deletions src/crawlee/storage_clients/_memory/_request_queue_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from logging import getLogger
from typing import TYPE_CHECKING

from typing_extensions import override
from typing_extensions import Self, override

from crawlee import Request
from crawlee._utils.crypto import crypto_random_object_id
Expand Down Expand Up @@ -65,7 +65,7 @@ async def open(
id: str | None,
name: str | None,
alias: str | None,
) -> MemoryRequestQueueClient:
) -> Self:
"""Open or create a new memory request queue client.

This method creates a new in-memory request queue instance. Unlike persistent storage implementations,
Expand Down
4 changes: 2 additions & 2 deletions src/crawlee/storage_clients/_sql/_dataset_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from typing import TYPE_CHECKING, Any

from sqlalchemy import Select, insert, select
from typing_extensions import override
from typing_extensions import Self, override

from crawlee.storage_clients._base import DatasetClient
from crawlee.storage_clients.models import DatasetItemsListPage, DatasetMetadata
Expand Down Expand Up @@ -78,7 +78,7 @@ async def open(
name: str | None,
alias: str | None,
storage_client: SqlStorageClient,
) -> SqlDatasetClient:
) -> Self:
"""Open an existing dataset or create a new one.

Args:
Expand Down
4 changes: 2 additions & 2 deletions src/crawlee/storage_clients/_sql/_key_value_store_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
from typing import TYPE_CHECKING, Any

from sqlalchemy import delete, select
from typing_extensions import override
from typing_extensions import Self, override

from crawlee._utils.file import infer_mime_type
from crawlee.storage_clients._base import KeyValueStoreClient
Expand Down Expand Up @@ -77,7 +77,7 @@ async def open(
name: str | None,
alias: str | None,
storage_client: SqlStorageClient,
) -> SqlKeyValueStoreClient:
) -> Self:
"""Open or create a SQL key-value store client.

This method attempts to open an existing key-value store from the SQL database. If a KVS with the specified
Expand Down
4 changes: 2 additions & 2 deletions src/crawlee/storage_clients/_sql/_request_queue_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from sqlalchemy import func, or_, select, update
from sqlalchemy.exc import SQLAlchemyError
from sqlalchemy.orm import load_only
from typing_extensions import NotRequired, override
from typing_extensions import NotRequired, Self, override

from crawlee import Request
from crawlee._utils.crypto import crypto_random_object_id
Expand Down Expand Up @@ -119,7 +119,7 @@ async def open(
name: str | None,
alias: str | None,
storage_client: SqlStorageClient,
) -> SqlRequestQueueClient:
) -> Self:
"""Open an existing request queue or create a new one.

This method first tries to find an existing queue by ID or name.
Expand Down