Skip to content

Commit

Permalink
Fix typing for post_upload_function io upload queue
Browse files Browse the repository at this point in the history
  • Loading branch information
einarmo committed Jan 4, 2024
1 parent acff7aa commit 02f306d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cognite/extractorutils/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,5 +16,5 @@
Cognite extractor utils is a Python package that simplifies the development of new extractors.
"""

__version__ = "6.2.0"
__version__ = "6.2.1"
from .base import Extractor
4 changes: 2 additions & 2 deletions cognite/extractorutils/uploader/files.py
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class IOFileUploadQueue(AbstractUploadQueue):
def __init__(
self,
cdf_client: CogniteClient,
post_upload_function: Optional[Callable[[List[Event]], None]] = None,
post_upload_function: Optional[Callable[[List[FileMetadata]], None]] = None,
max_queue_size: Optional[int] = None,
max_upload_interval: Optional[int] = None,
trigger_log_level: str = "DEBUG",
Expand Down Expand Up @@ -128,7 +128,7 @@ def upload(self) -> None:
self.files_written.inc(self.upload_queue_size)

try:
self._post_upload(self.upload_queue)
self._post_upload([el[0] for el in self.upload_queue])
except Exception as e:
self.logger.error("Error in upload callback: %s", str(e))
self.upload_queue.clear()
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "cognite-extractor-utils"
version = "6.2.0"
version = "6.2.1"
description = "Utilities for easier development of extractors for CDF"
authors = ["Mathias Lohne <[email protected]>"]
license = "Apache-2.0"
Expand Down

0 comments on commit 02f306d

Please sign in to comment.