Skip to content

Commit

Permalink
fix: adjust bd storage ci
Browse files Browse the repository at this point in the history
  • Loading branch information
cakeinsauce committed Sep 27, 2024
1 parent d2c8713 commit c62db73
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion annotation/tests/test_annotations.py
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ def test_upload_json_to_minio():
upload_json_to_minio(test_json, path_to_object, bucket_name, Mock())
mock_get_storage.assert_called_once_with(bucket_name)
mock_get_storage().upload_obj.assert_called_once_with(
target_path=path_to_object, file=ANY
target_path=path_to_object, file=ANY, overwrite=True
)


Expand Down
1 change: 1 addition & 0 deletions lib/badgerdoc_storage/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ build-backend = "poetry.core.masonry.api"
[tool.pylint.messages_control]
max-line-length = 79
disable = ["missing-docstring"]
ignored-argument-names="args|kwargs"

[tool.black]
line-length = 79
Expand Down
3 changes: 2 additions & 1 deletion lib/badgerdoc_storage/src/badgerdoc_storage/storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,8 +218,9 @@ def upload_obj(
target_path: str,
file: bytes,
content_type: Optional[str] = None,
overwrite: bool = False,
**kwargs: Any,
) -> None:
overwrite = kwargs.get("overwrite", False)
try:
blob_client = self.blob_service_client.get_blob_client(
self._container_name, target_path
Expand Down

0 comments on commit c62db73

Please sign in to comment.