wrong timezone offset on localize
Bug #1809979 reported by
Kalyan Bhetwal
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
pytz |
New
|
Undecided
|
Unassigned |
Bug Description
While trying to convert date from local time i.e. Asia/Kathmandu to UTC time, the offset for Kathmandu is taken as +05:41 which is wrong. Below code demonstrates it.
import pytz
from datetime import datetime
date_time = datetime(
utc = pytz.utc
tz = pytz.timezone(
dt = tz.localize(
print dt
The output offset obtained is +05:41 which is wrong since 'Asia/Kathmandu' is +05:45 from UTC
description: | updated |
tags: | added: timezone |
summary: |
- wrong timezone offset for datetime(18,12,28,10,12,22) + wrong timezone offset |
tags: | added: offset wrong |
summary: |
- wrong timezone offset + wrong timezone offset on localize |
To post a comment you must log in.
This happens particularly for timezone format of datetime( 18,12,28, 10,30,19) . Is there any solutions or fix to the problem