Skip to content

Commit 337db2d

Browse files
fix datetime
1 parent 0858664 commit 337db2d

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

services/director-v2/src/simcore_service_director_v2/utils/computations.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
import logging
33
from typing import Any
44

5+
import arrow
56
from models_library.projects_state import RunningState
67
from models_library.services import ServiceKeyVersion
78
from models_library.services_regex import SERVICE_KEY_RE
@@ -131,7 +132,7 @@ async def find_deprecated_tasks(
131132

132133
def _is_service_deprecated(service: dict[str, Any]) -> bool:
133134
if deprecation_date := service.get("deprecated"):
134-
deprecation_date = dt.datetime.fromisoformat(deprecation_date).replace(
135+
deprecation_date = arrow.get(deprecation_date).datetime.replace(
135136
tzinfo=dt.UTC
136137
)
137138
is_deprecated: bool = today > deprecation_date

0 commit comments

Comments
 (0)