Skip to content

Commit

Permalink
Merge pull request #45 from patroqueeet/hotfix/broken-datetime-str-co…
Browse files Browse the repository at this point in the history
…nversion

Hotfix/broken datetime str conversion
  • Loading branch information
alexandernst authored Aug 28, 2024
2 parents 99e3418 + 1fdb031 commit 07b1143
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,11 @@
# Changelog

## [4.2.1] - 2024-08-28

### Changed

- stable datetime str conversion

## [4.2] - 2024-08-26

### Added
Expand Down
4 changes: 2 additions & 2 deletions django_walletpass/models.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import datetime
import os
import re
import uuid
Expand All @@ -8,6 +7,7 @@
import secrets
import zipfile
from glob import glob
from dateutil.parser import parse as datetime_parse
from django.core.exceptions import ValidationError
from django.utils import timezone
from django.utils.module_loading import import_string
Expand Down Expand Up @@ -382,7 +382,7 @@ def parse_log(cls, log, message):
elif 'warning' in status:
status = 'warning'

log.created_at = datetime.datetime.strptime(timestamp_str, "%Y-%m-%d %H:%M:%S %p %z")
log.created_at = datetime_parse(timestamp_str)
log.status = status
log.task_type = task_type
log.device_id = device_id
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
setup(
name='django-walletpass',
python_requires='>=3.10.0',
version='4.2',
version='4.2.1',
author='Develatio Technologies S.L.',
author_email='[email protected]',
packages=find_packages(),
Expand Down

0 comments on commit 07b1143

Please sign in to comment.