Skip to content

Commit

Permalink
modified get_precision file
Browse files Browse the repository at this point in the history
  • Loading branch information
binni979 committed Apr 10, 2024
1 parent f0884da commit 4b3748b
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions pyQuARC/code/datetime_validator.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,6 @@ def _iso_datetime(datetime_string):
"""
REGEX = r"^(-?(?:[1-9][0-9]*)?[0-9]{4})-(1[0-2]|0[1-9])-(3[01]|0[1-9]|[12][0-9])T(2[0-3]|[01][0-9]):([0-5][0-9]):([0-5][0-9])(\.[0-9]+)?(Z|[+-](?:2[0-3]|[01][0-9]):[0-5][0-9])?$"
match_iso8601 = re.compile(REGEX).match
parts = datetime_string.split('.')
if len(parts) == 2:
datetime_string = parts[0] + '.' + parts[1][:3] + parts[1][len(parts[1]) - 1]
try:
if match_iso8601(datetime_string):
if datetime_string.endswith("Z"):
Expand Down

0 comments on commit 4b3748b

Please sign in to comment.