Skip to content

Commit

Permalink
[resotocore][fix] Try to make a string before (#1837)
Browse files Browse the repository at this point in the history
  • Loading branch information
aquamatthias committed Nov 24, 2023
1 parent 5340961 commit 3420035
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
4 changes: 2 additions & 2 deletions resotocore/resotocore/model/transform_kind_convert.py
Expand Up @@ -3,13 +3,13 @@


def datetime_before_now(duration_string: str) -> str:
duration = parse_duration(duration_string)
duration = parse_duration(str(duration_string))
timestamp = utc() - duration
return utc_str(timestamp)


def duration_until_now(at: str) -> str:
timestamp = from_utc(at)
timestamp = from_utc(str(at))
duration = utc() - timestamp
return duration_str(duration, precision=2)

Expand Down
6 changes: 5 additions & 1 deletion resotoshell/resotoshell/__main__.py
Expand Up @@ -209,7 +209,11 @@ def header_value(s: str) -> Tuple[str, str]:
default=False,
)
arg_parser.add_argument(
"--add-headers", help="Add a header to all requests. Format: key:value", nargs="*", type=header_value
"--add-headers",
help="Add a header to all requests. Format: key:value",
nargs="*",
default=[],
type=header_value,
)


Expand Down

0 comments on commit 3420035

Please sign in to comment.