
This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
Created on2013-06-03 20:51 byjwilk, last changed2022-04-11 14:57 byadmin. This issue is nowclosed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| iss18128.patch | flipmcf,2015-04-14 23:19 | review | ||
| issue18128.patch | flipmcf,2015-04-15 19:05 | review | ||
| Messages (10) | |||
|---|---|---|---|
| msg190563 -(view) | Author: Jakub Wilk (jwilk) | Date: 2013-06-03 20:51 | |
pygettext uses non-standard timestamp format in the POT-Creation-Date field. For example:POT-Creation-Date: 2013-06-03 22:31+CESTwhereas xgettext uses this format:POT-Creation-Date: 2013-06-03 22:31+0200You could use this code to generate timestamps in the same format as xgettext:from time import time, localtime, strftimefrom calendar import timegmdef gettext_timestamp(): now = int(time()) nowtuple = localtime(now) offset = timegm(nowtuple) - now sign = '-' if offset < 0 else '+' hour, minute = divmod(abs(offset) // 60, 60) return strftime('%Y-%m-%d %H:%M', nowtuple) + sign + '%02d%02d' % (hour, minute) | |||
| msg190564 -(view) | Author: Barry A. Warsaw (barry)*![]() | Date: 2013-06-03 20:54 | |
It's probably worth changing. My only concern would be backwards compatibility issues. | |||
| msg241025 -(view) | Author: Michael McFadden (flipmcf)* | Date: 2015-04-14 20:52 | |
I'm going to be adding some tests around pygettext tool and then tackling this. | |||
| msg241055 -(view) | Author: Michael McFadden (flipmcf)* | Date: 2015-04-14 23:19 | |
Patch File iss18128.patch adds test_i18n to start testing the entireTools/i18n package, and has a very simple fix. | |||
| msg241144 -(view) | Author: Michael McFadden (flipmcf)* | Date: 2015-04-15 19:05 | |
Post-review - new patch | |||
| msg241162 -(view) | Author: R. David Murray (r.david.murray)*![]() | Date: 2015-04-15 21:14 | |
Barry, would you be OK with just applying this to 3.5? We can add a porting note to whatsnew. My guess, though, is that no one is going to notice. | |||
| msg241163 -(view) | Author: R. David Murray (r.david.murray)*![]() | Date: 2015-04-15 21:16 | |
Oh, I forgot to say that the patch looks good to me. | |||
| msg241168 -(view) | Author: Barry A. Warsaw (barry)*![]() | Date: 2015-04-15 21:48 | |
@rdm: I'm pretty sure you're right about nobody noticing. :) Make it so! | |||
| msg241232 -(view) | Author: Roundup Robot (python-dev)![]() | Date: 2015-04-16 16:20 | |
New changesetc969413584cf by R David Murray in branch 'default':#18128: use standard +NNNN timezone format in POT-Creation-Date header.https://hg.python.org/cpython/rev/c969413584cf | |||
| msg241233 -(view) | Author: R. David Murray (r.david.murray)*![]() | Date: 2015-04-16 16:21 | |
Thanks, Michael. | |||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:57:46 | admin | set | github: 62328 |
| 2015-04-16 16:21:23 | r.david.murray | set | status: open -> closed versions: + Python 3.5 type: behavior messages: +msg241233 resolution: fixed stage: resolved |
| 2015-04-16 16:20:23 | python-dev | set | nosy: +python-dev messages: +msg241232 |
| 2015-04-15 21:48:01 | barry | set | messages: +msg241168 |
| 2015-04-15 21:16:48 | r.david.murray | set | messages: +msg241163 |
| 2015-04-15 21:14:28 | r.david.murray | set | nosy: +r.david.murray messages: +msg241162 |
| 2015-04-15 19:06:00 | flipmcf | set | files: +issue18128.patch messages: +msg241144 |
| 2015-04-14 23:19:16 | flipmcf | set | files: +iss18128.patch keywords: +patch messages: +msg241055 |
| 2015-04-14 20:52:52 | flipmcf | set | nosy: +flipmcf messages: +msg241025 |
| 2013-06-03 20:54:38 | barry | set | messages: +msg190564 |
| 2013-06-03 20:53:49 | barry | set | nosy: +barry |
| 2013-06-03 20:51:02 | jwilk | create | |