This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2008年10月09日 11:27 by skip.montanaro, last changed 2022年04月11日 14:56 by admin. This issue is now closed.
| Messages (2) | |||
|---|---|---|---|
| msg74570 - (view) | Author: Skip Montanaro (skip.montanaro) * (Python triager) | Date: 2008年10月09日 11:27 | |
While responding to a c.l.py question just now I discovered that numeric timezone offsets don't appear to be supported by either the time.strftime function or the _strptime module. I noticed on my Mac's strftime(3) man page that it supports a %Z format for TZ names and a %z format for numeric tz offsets. It seems Python should as well. |
|||
| msg118701 - (view) | Author: Alexander Belopolsky (belopolsky) * (Python committer) | Date: 2010年10月14日 17:54 | |
Closing as a duplicate of (closed) issue 6641. time.strftime appears to support %z on the platforms that support it in C strftime: >>> time.strftime("%z", time.localtime()) '-0400' |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:56:40 | admin | set | github: 48336 |
| 2010年10月15日 17:54:36 | georg.brandl | set | status: open -> closed |
| 2010年10月14日 17:54:47 | belopolsky | set | resolution: duplicate dependencies: - No obvious and correct way to get the time zone offset superseder: datetime.strptime doesn't support %z format ? messages: + msg118701 |
| 2010年08月07日 18:13:21 | terry.reedy | set | versions: + Python 3.2, - Python 2.6 |
| 2010年06月12日 06:05:57 | belopolsky | set | assignee: belopolsky dependencies: + No obvious and correct way to get the time zone offset nosy: + belopolsky |
| 2010年05月20日 20:34:05 | skip.montanaro | set | nosy:
- skip.montanaro -> (no value) |
| 2008年10月09日 11:27:25 | skip.montanaro | create | |