Skip to content

Commit 32f1f12

Browse files
author
Grzegorz Pustulka
committed
pre-commit
1 parent 243dd1c commit 32f1f12

File tree

3 files changed

+5
-9
lines changed

3 files changed

+5
-9
lines changed

stac_fastapi/core/stac_fastapi/core/core.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -514,7 +514,9 @@ async def post_search(
514514
)
515515
except (ValueError, TypeError) as e:
516516
# Handle invalid interval formats if return_date fails
517-
logger.error(f"Invalid interval format: {search_request.datetime}, error: {e}")
517+
logger.error(
518+
f"Invalid interval format: {search_request.datetime}, error: {e}"
519+
)
518520
datetime_search = None
519521

520522
if search_request.bbox:

stac_fastapi/elasticsearch/stac_fastapi/elasticsearch/database_logic.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
import logging
55
from base64 import urlsafe_b64decode, urlsafe_b64encode
66
from copy import deepcopy
7-
from typing import Any, Dict, Iterable, List, Optional, Tuple, Type, Union
7+
from typing import Any, Dict, Iterable, List, Optional, Tuple, Type
88

99
import attr
1010
import elasticsearch.helpers as helpers

stac_fastapi/opensearch/stac_fastapi/opensearch/database_logic.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@
5959
)
6060
from stac_fastapi.types.errors import ConflictError, NotFoundError
6161
from stac_fastapi.types.links import resolve_links
62-
from stac_fastapi.types.rfc3339 import DateTimeType
6362
from stac_fastapi.types.stac import Collection, Item
6463

6564
logger = logging.getLogger(__name__)
@@ -1289,12 +1288,7 @@ async def delete_collection(self, collection_id: str, **kwargs: Any):
12891288
index=COLLECTIONS_INDEX, id=collection_id, refresh=refresh
12901289
)
12911290
# Delete the item index for the collection
1292-
try:
1293-
await delete_item_index(collection_id)
1294-
except Exception as e:
1295-
logger.error(
1296-
f"Failed to delete item index for collection {collection_id}: {e}"
1297-
)
1291+
await delete_item_index(collection_id)
12981292

12991293
async def bulk_async(
13001294
self,

0 commit comments

Comments
 (0)