Skip to content
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

Wrong egypt timezone when using datetime replace #98

Open
Om4ar opened this issue Mar 23, 2023 · 1 comment
Open

Wrong egypt timezone when using datetime replace #98

Om4ar opened this issue Mar 23, 2023 · 1 comment

Comments

@Om4ar
Copy link

Om4ar commented Mar 23, 2023

hello

when i run the following code

from datetime import datetime
from pytz import timezone

print(datetime.strptime("2023-03-21T09:05:46.807Z", "%Y-%m-%dT%H:%M:%S.%fZ").replace(tzinfo=timezone("Africa/Cairo")))

it prints
2023-03-21 09:05:46.807000+02:05. with egypt offset as +02:05 but it should have been +02:00

@ryanwild7
Copy link

The same with Perth Time Zone

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants