Skip to content

bug: aws scalar type for AWSDateTime should include milliseconds #503

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
michaelbrewer opened this issue Jul 2, 2021 · 0 comments · Fixed by #504
Closed

bug: aws scalar type for AWSDateTime should include milliseconds #503

michaelbrewer opened this issue Jul 2, 2021 · 0 comments · Fixed by #504
Labels
bug Something isn't working

Comments

@michaelbrewer
Copy link
Contributor

michaelbrewer commented Jul 2, 2021

What were you trying to accomplish?

Expected Behavior

AWSDateTime - An extended ISO 8601 date and time string in the format YYYY-MM-DDThh:mm:ss.sssZ.

Current Behavior

AWSDateTime is not including the millisecond part sss.

Possible Solution

Generate timestamps to include the milliseconds

Steps to Reproduce (for bugs)

> print(aws_datetime())
2021-07-02T17:09:47Z

Environment

  • Powertools version used: 1.17.0
  • Packaging format (Layers, PyPi): PyPi
  • AWS Lambda function runtime: Python 3.8
@michaelbrewer michaelbrewer added bug Something isn't working triage Pending triage from maintainers labels Jul 2, 2021
michaelbrewer added a commit to gyft/aws-lambda-powertools-python that referenced this issue Jul 2, 2021
Set the formatted outout to include microseconds `"%Y-%m-%dT%H:%M:%S.%f"`

>NOTE: Will need to confirm if microseconds work over milliseconds

fixes aws-powertools#503
@heitorlessa heitorlessa removed the triage Pending triage from maintainers label Feb 13, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants