Skip to content
This repository was archived by the owner on Mar 26, 2025. It is now read-only.

Commit 7f64f39

Browse files
macwilksrhinos
andauthored
Patch Datetime RESTful API Field Error (#165)
* Fix Datetime Fields Throwing Errors * Bump Version --------- Co-authored-by: srhinos <[email protected]>
1 parent 18049db commit 7f64f39

File tree

2 files changed

+5
-14
lines changed

2 files changed

+5
-14
lines changed

hatchet_sdk/clients/rest/api/workflow_api.py

Lines changed: 4 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
Do not edit the class manually.
1212
""" # noqa: E501
1313

14-
import warnings
1514
from datetime import datetime
1615
from typing import Any, Dict, List, Optional, Tuple, Union
1716

@@ -2186,9 +2185,7 @@ def _workflow_run_get_metrics_serialize(
21862185
_query_params.append(
21872186
(
21882187
"createdAfter",
2189-
created_after.strftime(
2190-
self.api_client.configuration.datetime_format
2191-
),
2188+
created_after.isoformat(),
21922189
)
21932190
)
21942191
else:
@@ -2199,9 +2196,7 @@ def _workflow_run_get_metrics_serialize(
21992196
_query_params.append(
22002197
(
22012198
"createdBefore",
2202-
created_before.strftime(
2203-
self.api_client.configuration.datetime_format
2204-
),
2199+
created_before.isoformat(),
22052200
)
22062201
)
22072202
else:
@@ -2790,9 +2785,7 @@ def _workflow_run_list_serialize(
27902785
_query_params.append(
27912786
(
27922787
"createdAfter",
2793-
created_after.strftime(
2794-
self.api_client.configuration.datetime_format
2795-
),
2788+
created_after.isoformat(),
27962789
)
27972790
)
27982791
else:
@@ -2803,9 +2796,7 @@ def _workflow_run_list_serialize(
28032796
_query_params.append(
28042797
(
28052798
"createdBefore",
2806-
created_before.strftime(
2807-
self.api_client.configuration.datetime_format
2808-
),
2799+
created_before.isoformat(),
28092800
)
28102801
)
28112802
else:

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "hatchet-sdk"
3-
version = "0.36.11"
3+
version = "0.36.12"
44
description = ""
55
authors = ["Alexander Belanger <[email protected]>"]
66
readme = "README.md"

0 commit comments

Comments
 (0)