Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8230599
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T17:11:20+00:00 2026-06-07T17:11:20+00:00

Possible Duplicate: Python datetime object show wrong timezone offset import pytz, datetime pytz.timezone("Asia/Calcutta") prints

  • 0

Possible Duplicate:
Python datetime object show wrong timezone offset

import pytz, datetime

 pytz.timezone("Asia/Calcutta")

prints the following:

< DstTzInfo 'Asia/Calcutta' HMT+5:53:00 STD >

Why it is not 05:30 hrs? I am in time zone America/Los_Angeles.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T17:11:22+00:00Added an answer on June 7, 2026 at 5:11 pm

    Time zones change over the years. According to http://www.prokerala.com/travel/timezones/Asia/Kolkata?mode=history the original offset for that zone was 5.88888888889 hours, or 5 hours 53 minutes. pytz will use the proper offset and nomenclature once you assign the zone to an actual date.

    >>> tz = pytz.timezone("Asia/Calcutta")
    >>> tz
    <DstTzInfo 'Asia/Calcutta' HMT+5:53:00 STD>
    >>> tz.localize(datetime.datetime(1901, 7, 10, 12, 0))
    datetime.datetime(1901, 7, 10, 12, 0, tzinfo=<DstTzInfo 'Asia/Calcutta' HMT+5:53:00 STD>)
    >>> tz.localize(datetime.datetime(2012, 7, 10, 12, 0))
    datetime.datetime(2012, 7, 10, 12, 0, tzinfo=<DstTzInfo 'Asia/Calcutta' IST+5:30:00 STD>)
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Possible Duplicate: Convert Date String to DateTime Object in Python Is there an easy
Possible Duplicate: Python: Get object by id Typically when you see the string representation
Possible Duplicate: Python package structure Hello, I'm looking to import a python file that
Possible Duplicate: Python import MySQLdb error - Mac 10.6 I've tried everything I can
Possible Duplicate: Python - Determine the type of an object? I want 'complex' to
Possible Duplicate: Dynamic module import in Python I have a list of modules, like
Possible Duplicate: Python JSON serialize a Decimal object I have the following SQL: SELECT
Possible Duplicate: Python : how to append new elements in a list of list?
Possible Duplicate: Python: What is the best way to check if a list is
Possible Duplicate: Python: Behaviour of increment and decrement operators >>> a=2 >>> ++a 2

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.