# HG changeset patch # User Dmitriy Morozov <morozov@cs.duke.edu> # Date 1199817228 18000 # Node ID e5b03298394ee5368e84f0a6dd9d215a596dd538 # Parent e78a97664dbaf58b5c7e831e0b9ae342c0bed2bc Fixed using Mirko Friedenhagen's observations the date bug (c56) + fixed timezones of all bugs diff -r e78a97664dba -r e5b03298394e .issues/8e4d2c2d12eb0169 --- a/.issues/8e4d2c2d12eb0169 Sun Jan 06 01:18:02 2008 -0500 +++ b/.issues/8e4d2c2d12eb0169 Tue Jan 08 13:33:48 2008 -0500 @@ -1,6 +1,6 @@ From artemis Sat Dec 29 07:57:17 2007 From: Dmitriy Morozov <morozov@cs.duke.edu> -Date: Sat, 29 Dec 2007 02:52:52 EST +Date: Sat, 29 Dec 2007 02:52:52 -0500 State: fixed Subject: filters Message-Id: <8e4d2c2d12eb0169-0-artemis@metatron> @@ -21,7 +21,7 @@ From MAILER-DAEMON Sun Dec 30 13:37:54 2007 From: Dmitriy Morozov <morozov@cs.duke.edu> -Date: Sun, 30 Dec 2007 08:37:54 EST +Date: Sun, 30 Dec 2007 08:37:54 -0500 Subject: properties changes (state) Message-Id: <8e4d2c2d12eb0169-1-artemis@metatron> In-Reply-To: <8e4d2c2d12eb0169-0-artemis@metatron> diff -r e78a97664dba -r e5b03298394e .issues/95536ae767c2743a --- a/.issues/95536ae767c2743a Sun Jan 06 01:18:02 2008 -0500 +++ b/.issues/95536ae767c2743a Tue Jan 08 13:33:48 2008 -0500 @@ -1,6 +1,6 @@ From artemis Sat Dec 29 07:52:09 2007 From: Dmitriy Morozov <morozov@cs.duke.edu> -Date: Sat, 29 Dec 2007 02:50:26 EST +Date: Sat, 29 Dec 2007 02:50:26 -0500 State: new Subject: attachments in iadd Message-Id: <95536ae767c2743a-0-artemis@metatron> diff -r e78a97664dba -r e5b03298394e .issues/b7cdd0ec985471b7 --- a/.issues/b7cdd0ec985471b7 Sun Jan 06 01:18:02 2008 -0500 +++ b/.issues/b7cdd0ec985471b7 Tue Jan 08 13:33:48 2008 -0500 @@ -1,6 +1,6 @@ From artemis Fri Jan 4 18:24:46 2008 From: Dmitriy Morozov <morozov@cs.duke.edu> -Date: Fri, 04 Jan 2008 13:16:44 EST +Date: Fri, 04 Jan 2008 13:16:44 -0500 State: fixed Subject: Thread messages by In-Reply-To Message-Id: <b7cdd0ec985471b7-0-artemis@metatron> @@ -12,7 +12,7 @@ From artemis Sun Jan 6 06:04:32 2008 From: Dmitriy Morozov <morozov@cs.duke.edu> -Date: Sun, 06 Jan 2008 01:04:32 EST +Date: Sun, 06 Jan 2008 01:04:32 -0500 Subject: properties changes (state) Message-Id: <b7cdd0ec985471b7-f5b5087bf1c336ab-artemis@metatron> References: <b7cdd0ec985471b7-0-artemis@metatron> diff -r e78a97664dba -r e5b03298394e .issues/c568146d3275c22b --- a/.issues/c568146d3275c22b Sun Jan 06 01:18:02 2008 -0500 +++ b/.issues/c568146d3275c22b Tue Jan 08 13:33:48 2008 -0500 @@ -17,8 +17,8 @@ Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v915) Subject: hg ishow fails in clone of Artemis-repo -Date: Sat, 5 Jan 2008 00:31:27 +0100 -State: new +Date: Sat, 05 Jan 2008 00:31:27 +0100 +State: fixed X-Mailer: Apple Mail (2.915) X-Provags-ID: V01U2FsdGVkX1/JysvjyYiL3YHLT6W7yfO6FZ1JMB6PepAft/b jnXeHpRbt2ZogH7u/u+9jEuj7D5SulS51Scfvx4LgDgb4pctZs @@ -65,7 +65,7 @@ Mirko From morozov@cs.duke.edu Fri Jan 4 18:34:36 2008 -Date: Fri, 4 Jan 2008 18:34:36 -0500 +Date: Fri, 04 Jan 2008 18:34:36 -0500 From: Dmitriy Morozov <morozov@cs.duke.edu> To: Mirko Friedenhagen <mirko@friedenhagen.de> Subject: Re: hg ishow fails in clone of Artemis-repo @@ -146,7 +146,7 @@ Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v915) Subject: Re: hg ishow fails in clone of Artemis-repo -Date: Sat, 5 Jan 2008 00:43:23 +0100 +Date: Sat, 05 Jan 2008 00:43:23 +0100 References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> <20080104233436.GA1930@cs.duke.edu> X-Mailer: Apple Mail (2.915) X-Provags-ID: V01U2FsdGVkX1/lGFmR/n0Vn+KixPR/52KDdWD8RANfnQ68xtl @@ -199,7 +199,7 @@ Mirko From morozov@cs.duke.edu Sat Jan 5 07:47:08 2008 -Date: Sat, 5 Jan 2008 07:47:08 -0500 +Date: Sat, 05 Jan 2008 07:47:08 -0500 From: Dmitriy Morozov <morozov@cs.duke.edu> To: Mirko Friedenhagen <mirko@friedenhagen.de> Subject: Re: hg ishow fails in clone of Artemis-repo @@ -284,7 +284,7 @@ Content-Type: multipart/mixed; boundary=Apple-Mail-27-69865486 Mime-Version: 1.0 (Apple Message framework v915) Subject: Re: hg ishow fails in clone of Artemis-repo -Date: Sat, 5 Jan 2008 22:18:01 +0100 +Date: Sat, 05 Jan 2008 22:18:01 +0100 References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> <20080104233436.GA1930@cs.duke.edu> <312C0172-3EF2-488A-A993-CF56C183F9A0@friedenhagen.de> <20080105124708.GA7043@cs.duke.edu> X-Mailer: Apple Mail (2.915) X-Provags-ID: V01U2FsdGVkX18U2SPmtxdIc/97m419K3u6bNHAGoJX7Zg8bRM @@ -2079,7 +2079,7 @@ --Apple-Mail-27-69865486-- From morozov@cs.duke.edu Sun Jan 6 00:45:57 2008 -Date: Sun, 6 Jan 2008 00:45:57 -0500 +Date: Sun, 06 Jan 2008 00:45:57 -0500 From: Dmitriy Morozov <morozov@cs.duke.edu> To: Mirko Friedenhagen <mirko@friedenhagen.de> Subject: Re: hg ishow fails in clone of Artemis-repo @@ -2117,7 +2117,7 @@ >and default: From morozov@cs.duke.edu Sun Jan 6 00:46:30 2008 -Date: Sun, 6 Jan 2008 00:46:30 -0500 +Date: Sun, 06 Jan 2008 00:46:30 -0500 From: Dmitriy Morozov <morozov@cs.duke.edu> To: Mirko Friedenhagen <mirko@friedenhagen.de> Subject: Re: hg ishow fails in clone of Artemis-repo @@ -2439,3 +2439,510 @@ --oyUTqETQ0mS9luUI-- +From morozov@cs.duke.edu Sun Jan 6 01:23:03 2008 +Date: Sun, 06 Jan 2008 01:23:03 -0500 +From: Dmitriy Morozov <morozov@cs.duke.edu> +To: Mirko Friedenhagen <mirko@friedenhagen.de> +Subject: Re: hg ishow fails in clone of Artemis-repo +Message-ID: <20080106062303.GA12860@cs.duke.edu> +References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> <20080104233436.GA1930@cs.duke.edu> <312C0172-3EF2-488A-A993-CF56C183F9A0@friedenhagen.de> <20080105124708.GA7043@cs.duke.edu> <8B223BED-8A46-4129-A4F3-76B50A890874@friedenhagen.de> <20080106054557.GA12219@cs.duke.edu> <20080106054630.GB12219@cs.duke.edu> +Mime-Version: 1.0 +Content-Type: text/plain; charset=koi8-r +Content-Disposition: inline +In-Reply-To: <20080106054630.GB12219@cs.duke.edu> +User-Agent: Mutt/1.4.2.2i +Status: RO +Content-Length: 9705 +Lines: 303 + +Actually, you can just pull the changes from the Artemis repository on +the Web. I've put them there as well. + +Best, +Dmitriy + +On Sun, Jan 06, 2008 at 12:46:30AM -0500, Dmitriy Morozov wrote: +>Forgot the attachment. Dmitriy +> +>On Sun, Jan 06, 2008 at 12:45:57AM -0500, Dmitriy Morozov wrote: +>>Hi, Mirko, +>> +>>Very strange. I still don't see what the problem is. Try the attached +>>version of artemis.py. It's not really a fix: it's the fix of the +>>immediate problem, but if you try to use -d flag of ilist, the problem +>>will come back. Meanwhile, I'll think about it some more. +>> +>>Best, +>>Dmitriy +>> +>>On Sat, Jan 05, 2008 at 10:18:01PM +0100, Mirko Friedenhagen wrote: +>>>Am 05.01.2008 um 13:47 schrieb Dmitriy Morozov: +>>> +>>>>Hi, Mirko, +>>>> +>>>>I'm unable to replicate the problem with mercrial/crew. Can you send +>>>>me util.py (i.e., mercurial/util.py) from the repository that you are +>>>>actually using? +>>>I did not alter anything in it, see the diff between my local branch +>>>and default: + +># Author: Dmitriy Morozov <hg@foxcub.org>, 2007 +> +>"""A very simple and lightweight issue tracker for Mercurial.""" +> +>from mercurial import hg, util +>from mercurial.i18n import _ +>import os, time, random, mailbox, glob, socket, ConfigParser +> +> +>state = {'new': 'new', 'fixed': 'fixed'} +>state['default'] = state['new'] +>issues_dir = ".issues" +>filter_prefix = ".filter" +>date_format = '%a, %d %b %Y %H:%M:%S %Z' +> +> +>def ilist(ui, repo, **opts): +> """List issues associated with the project""" +> +> # Process options +> show_all = opts['all'] +> properties = [] +> match_date, date_match = False, lambda x: True +> if opts['date']: +> match_date, date_match = True, util.matchdate(opts['date']) +> +> # Find issues +> issues_path = os.path.join(repo.root, issues_dir) +> if not os.path.exists(issues_path): return +> +> issues = glob.glob(os.path.join(issues_path, '*')) +> +> # Process filter +> if opts['filter']: +> filters = glob.glob(os.path.join(issues_path, filter_prefix + '*')) +> config = ConfigParser.SafeConfigParser() +> config.read(filters) +> if not config.has_section(opts['filter']): +> ui.warning('No filter %s defined\n', opts['filter']) +> else: +> properties += config.items(opts['filter']) +> +> _get_properties(opts['property']) +> +> for issue in issues: +> mbox = mailbox.mbox(issue) +> property_match = True +> for property,value in properties: +> property_match = property_match and (mbox[0][property] == value) +> if not show_all and (not properties or not property_match) and (properties or mbox[0]['State'].upper() == state['fixed'].upper()): continue +> +> +> if match_date and not date_match(util.parsedate(mbox[0]['date'], [date_format])[0]): continue +> ui.write("%s (%d) [%s]: %s\n" % (issue[len(issues_path)+1:], # +1 for trailing / +> len(mbox)-1, # number of replies (-1 for self) +> mbox[0]['State'], +> mbox[0]['Subject'])) +> +> +>def iadd(ui, repo, id = None, comment = 0): +> """Adds a new issue, or comment to an existing issue ID or its comment COMMENT""" +> +> comment = int(comment) +> +> # First, make sure issues have a directory +> issues_path = os.path.join(repo.root, issues_dir) +> if not os.path.exists(issues_path): os.mkdir(issues_path) +> +> if id: +> issue_fn, issue_id = _find_issue(ui, repo, id) +> if not issue_fn: +> ui.warn('No such issue\n') +> return +> +> user = ui.username() +> +> default_issue_text = "From: %s\nDate: %s\n" % (user, time.strftime(date_format)) +> if not id: +> default_issue_text += "State: %s\n" % state['default'] +> default_issue_text += "Subject: brief description\n\n" +> default_issue_text += "Detailed description." +> +> issue = ui.edit(default_issue_text, user) +> if issue.strip() == '': +> ui.warn('Empty issue, ignoring\n') +> return +> if issue.strip() == default_issue_text: +> ui.warn('Unchanged issue text, ignoring\n') +> return +> +> # Create the message +> msg = mailbox.mboxMessage(issue) +> msg.set_from('artemis', True) +> +> # Pick random filename +> if not id: +> issue_fn = issues_path +> while os.path.exists(issue_fn): +> issue_id = _random_id() +> issue_fn = os.path.join(issues_path, issue_id) +> # else: issue_fn already set +> +> # Add message to the mailbox +> mbox = mailbox.mbox(issue_fn) +> if id and comment not in mbox: +> ui.warn('No such comment number in mailbox, commenting on the issue itself\n') +> if not id: +> msg.add_header('Message-Id', "<%s-0-artemis@%s>" % (issue_id, socket.gethostname())) +> else: +> msg.add_header('Message-Id', "<%s-%s-artemis@%s>" % (issue_id, _random_id(), socket.gethostname())) +> msg.add_header('References', mbox[(comment < len(mbox) and comment) or 0]['Message-Id']) +> mbox.add(msg) +> mbox.close() +> +> # If adding issue, add the new mailbox to the repository +> if not id: +> repo.add([issue_fn[(len(repo.root)+1):]]) # +1 for the trailing / +> ui.status('Added new issue %s\n' % issue_id) +> +> +>def ishow(ui, repo, id, comment = 0, **opts): +> """Shows issue ID, or possibly its comment COMMENT""" +> +> comment = int(comment) +> issue, id = _find_issue(ui, repo, id) +> if not issue: return +> mbox = mailbox.mbox(issue) +> +> if opts['all']: +> ui.write('='*70 + '\n') +> for i in xrange(len(mbox)): +> _write_message(ui, mbox[i], i) +> ui.write('-'*70 + '\n') +> return +> +> _show_mbox(ui, mbox, comment) +> +> +>def iupdate(ui, repo, id, **opts): +> """Update properties of issue ID""" +> +> issue, id = _find_issue(ui, repo, id) +> if not issue: return +> +> properties = _get_properties(opts['property']) +> +> # Read the issue +> mbox = mailbox.mbox(issue) +> msg = mbox[0] +> +> # Fix the properties +> properties_text = '' +> for property, value in properties: +> msg.replace_header(property, value) +> properties_text += '%s=%s\n' % (property, value) +> mbox[0] = msg +> +> # Write down a comment about updated properties +> if properties and not opts['no_property_comment']: +> user = ui.username() +> properties_text = "From: %s\nDate: %s\nSubject: properties changes (%s)\n\n%s" % \ +> (user, time.strftime(date_format), +> _pretty_list(list(set([property for property, value in properties]))), +> properties_text) +> msg = mailbox.mboxMessage(properties_text) +> msg.add_header('Message-Id', "<%s-%s-artemis@%s>" % (id, _random_id(), socket.gethostname())) +> msg.add_header('References', mbox[0]['Message-Id']) +> msg.set_from('artemis', True) +> mbox.add(msg) +> mbox.flush() +> +> # Show updated message +> _show_mbox(ui, mbox, 0) +> +> +>def _find_issue(ui, repo, id): +> issues_path = os.path.join(repo.root, issues_dir) +> if not os.path.exists(issues_path): return False +> +> issues = glob.glob(os.path.join(issues_path, id + '*')) +> +> if len(issues) == 0: +> return False, 0 +> elif len(issues) > 1: +> ui.status("Multiple choices:\n") +> for i in issues: ui.status(' ', i[len(issues_path)+1:], '\n') +> return False, 0 +> +> return issues[0], issues[0][len(issues_path)+1:] +> +>def _get_properties(property_list): +> return [p.split('=') for p in property_list] +> +>def _write_message(ui, message, index = 0): +> if index: ui.write("Comment: %d\n" % index) +> if ui.verbose: +> ui.write(message.as_string().strip() + '\n') +> else: +> if 'From' in message: ui.write('From: %s\n' % message['From']) +> if 'Date' in message: ui.write('Date: %s\n' % message['Date']) +> if 'Subject' in message: ui.write('Subject: %s\n' % message['Subject']) +> if 'State' in message: ui.write('State: %s\n' % message['State']) +> ui.write('\n' + message.get_payload().strip() + '\n') +> +>def _show_mbox(ui, mbox, comment): +> # Output the issue (or comment) +> if comment >= len(mbox): +> comment = 0 +> ui.warn('Comment out of range, showing the issue itself\n') +> msg = mbox[comment] +> ui.write('='*70 + '\n') +> if comment: +> ui.write('Subject: %s\n' % mbox[0]['Subject']) +> ui.write('State: %s\n' % mbox[0]['State']) +> ui.write('-'*70 + '\n') +> _write_message(ui, msg, comment) +> ui.write('-'*70 + '\n') +> +> # Read the mailbox into the messages and children dictionaries +> messages = {} +> children = {} +> for i in xrange(len(mbox)): +> m = mbox[i] +> messages[m['Message-Id']] = (i,m) +> children.setdefault(m['References'], []).append(m['Message-Id']) +> children[None] = [] # Safeguard against infinte loop on empty Message-Id +> +> # Iterate over children +> id = msg['Message-Id'] +> id_stack = (id in children and map(lambda x: (x, 1), reversed(children[id]))) or [] +> if not id_stack: return +> ui.write('Comments:\n') +> while id_stack: +> id,offset = id_stack.pop() +> id_stack += (id in children and map(lambda x: (x, offset+1), reversed(children[id]))) or [] +> index, msg = messages[id] +> ui.write(' '*offset + ('%d: ' % index) + msg['Subject'] + '\n') +> ui.write('-'*70 + '\n') +> +>def _pretty_list(lst): +> s = '' +> for i in lst: +> s += i + ', ' +> return s[:-2] +> +>def _random_id(): +> return "%x" % random.randint(2**63, 2**64-1) +> +> +>cmdtable = { +> 'ilist': (ilist, +> [('a', 'all', False, +> 'list all issues (by default only those with state new)'), +> ('p', 'property', [], +> 'list issues with specific field values (e.g., -p state=fixed)'), +> ('d', 'date', '', 'restrict to issues matching the date (e.g., -d ">12/28/2007)"'), +> ('f', 'filter', '', 'restrict to pre-defined filter (in %s/%s*)' % (issues_dir, filter_prefix))], +> _('hg ilist [OPTIONS]')), +> 'iadd': (iadd, +> [], +> _('hg iadd [ID] [COMMENT]')), +> 'ishow': (ishow, +> [('a', 'all', None, 'list all comments')], +> _('hg ishow [OPTIONS] ID [COMMENT]')), +> 'iupdate': (iupdate, +> [('p', 'property', [], +> 'update properties (e.g., -p state=fixed)'), +> ('n', 'no-property-comment', None, +> 'do not add a comment about changed properties')], +> _('hg iupdate [OPTIONS] ID')) +>} + + +From mirko@friedenhagen.de Mon Jan 7 14:48:39 2008 +Return-Path: <mirko@friedenhagen.de> +X-Spam-Checker-Version: SpamAssassin 3.2.2 (2007-07-23) on one.cs.duke.edu +X-Spam-Level: +X-Spam-Status: No, score=-1.8 required=5.0 tests=AWL,BAYES_00 autolearn=ham + version=3.2.2 +Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.174]) + by one.cs.duke.edu (8.14.0/8.14.0) with ESMTP id m07Jmcp6010818 + for <morozov@cs.duke.edu>; Mon, 7 Jan 2008 14:48:38 -0500 (EST) +Received: from borg.local (HSI-KBW-085-216-123-176.hsi.kabelbw.de [85.216.123.176]) + by mrelayeu.kundenserver.de (node=mrelayeu4) with ESMTP (Nemesis) + id 0ML21M-1JBxxU3FPf-0006GX; Mon, 07 Jan 2008 20:48:32 +0100 +Message-Id: <BCEC116C-7113-4873-B098-05ACDE943A72@friedenhagen.de> +From: Mirko Friedenhagen <mirko@friedenhagen.de> +To: Dmitriy Morozov <morozov@cs.duke.edu> +In-Reply-To: <20080106062303.GA12860@cs.duke.edu> +Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes +Content-Transfer-Encoding: 7bit +Mime-Version: 1.0 (Apple Message framework v915) +Subject: Re: hg ishow fails in clone of Artemis-repo +Date: Mon, 07 Jan 2008 20:48:28 +0100 +References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> <20080104233436.GA1930@cs.duke.edu> <312C0172-3EF2-488A-A993-CF56C183F9A0@friedenhagen.de> <20080105124708.GA7043@cs.duke.edu> <8B223BED-8A46-4129-A4F3-76B50A890874@friedenhagen.de> <20080106054557.GA12219@cs.duke.edu> <20080106054630.GB12219@cs.duke.edu> <20080106062303.GA12860@cs.duke.edu> +X-Mailer: Apple Mail (2.915) +X-Provags-ID: V01U2FsdGVkX180vJsLizprsH5HFEaivi29mMVU4KUVP4sc9S/ + 8gvUFq6zpfnOswNDLfqqQUEOo71JI9E82xPOCeBWYO6HsENm3e + aYk5cubORJodMGX7f+ung== +Status: RO +Content-Length: 417 +Lines: 16 + +Am 06.01.2008 um 07:23 schrieb Dmitriy Morozov: +> Actually, you can just pull the changes from the Artemis repository on +> the Web. I've put them there as well. +> + +Thanks, I just pulled to e78a97664dba and ilist is now working without +option -d. +I just checked wether this was a "LANG"-related problem but the error +still occurs with LANGs set to: +de_DE.UTF-8 +C +en_US +so it must be something else. + +Regards +Mirko + +From mirko@friedenhagen.de Mon Jan 7 15:51:53 2008 +Return-Path: <mirko@friedenhagen.de> +X-Spam-Checker-Version: SpamAssassin 3.2.2 (2007-07-23) on one.cs.duke.edu +X-Spam-Level: +X-Spam-Status: No, score=-2.0 required=5.0 tests=AWL,BAYES_00 autolearn=ham + version=3.2.2 +Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.177]) + by one.cs.duke.edu (8.14.0/8.14.0) with ESMTP id m07KpqWA020073 + for <morozov@cs.duke.edu>; Mon, 7 Jan 2008 15:51:52 -0500 (EST) +Received: from borg.local (HSI-KBW-085-216-123-176.hsi.kabelbw.de [85.216.123.176]) + by mrelayeu.kundenserver.de (node=mrelayeu7) with ESMTP (Nemesis) + id 0ML2xA-1JBywk2eIR-0000fy; Mon, 07 Jan 2008 21:51:46 +0100 +Message-Id: <1ACD99E9-9100-4C7D-916C-F3516EC9CF66@friedenhagen.de> +From: Mirko Friedenhagen <mirko@friedenhagen.de> +To: Dmitriy Morozov <morozov@cs.duke.edu> +In-Reply-To: <20080106062303.GA12860@cs.duke.edu> +Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes +Content-Transfer-Encoding: 7bit +Mime-Version: 1.0 (Apple Message framework v915) +Subject: Re: hg ishow fails in clone of Artemis-repo +Date: Mon, 07 Jan 2008 21:51:45 +0100 +References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> <20080104233436.GA1930@cs.duke.edu> <312C0172-3EF2-488A-A993-CF56C183F9A0@friedenhagen.de> <20080105124708.GA7043@cs.duke.edu> <8B223BED-8A46-4129-A4F3-76B50A890874@friedenhagen.de> <20080106054557.GA12219@cs.duke.edu> <20080106054630.GB12219@cs.duke.edu> <20080106062303.GA12860@cs.duke.edu> +X-Mailer: Apple Mail (2.915) +X-Provags-ID: V01U2FsdGVkX18QJcYZDo6Q37uJfFynUsBGK2GGByd94i/JhM6 + I9MfCwpXS9DUnY0O0ZIhHan+nj+Gx7xd+r8zc31Da+yFftsUtL + FD+bmLhzp9S5QOyPPuamA== +Status: RO +Content-Length: 265 +Lines: 12 + +Hello Dmitry, + +I was digging a bit: +http://www.faqs.org/rfcs/rfc2822.html +states a numeric timezone must be used (see "A.6.2. Obsolete dates", +section 4.3. and 3.3.). + +Though I do not understand, why the other dates are parsed without a +problem. + +Regards +Mirko + +From mirko@friedenhagen.de Mon Jan 7 16:27:35 2008 +Return-Path: <mirko@friedenhagen.de> +X-Spam-Checker-Version: SpamAssassin 3.2.2 (2007-07-23) on one.cs.duke.edu +X-Spam-Level: +X-Spam-Status: No, score=-2.1 required=5.0 tests=AWL,BAYES_00 autolearn=ham + version=3.2.2 +Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.177]) + by one.cs.duke.edu (8.14.0/8.14.0) with ESMTP id m07LRYaF024588 + for <morozov@cs.duke.edu>; Mon, 7 Jan 2008 16:27:34 -0500 (EST) +Received: from borg.local (HSI-KBW-085-216-123-176.hsi.kabelbw.de [85.216.123.176]) + by mrelayeu.kundenserver.de (node=mrelayeu0) with ESMTP (Nemesis) + id 0MKwh2-1JBzVI0J5o-00061N; Mon, 07 Jan 2008 22:27:28 +0100 +Message-Id: <13CC4175-53F2-4ED1-94E7-075922A02DF7@friedenhagen.de> +From: Mirko Friedenhagen <mirko@friedenhagen.de> +To: Dmitriy Morozov <morozov@cs.duke.edu> +In-Reply-To: <20080106062303.GA12860@cs.duke.edu> +Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes +Content-Transfer-Encoding: 7bit +Mime-Version: 1.0 (Apple Message framework v915) +Subject: Re: hg ishow fails in clone of Artemis-repo +Date: Mon, 07 Jan 2008 22:27:28 +0100 +References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> <20080104233436.GA1930@cs.duke.edu> <312C0172-3EF2-488A-A993-CF56C183F9A0@friedenhagen.de> <20080105124708.GA7043@cs.duke.edu> <8B223BED-8A46-4129-A4F3-76B50A890874@friedenhagen.de> <20080106054557.GA12219@cs.duke.edu> <20080106054630.GB12219@cs.duke.edu> <20080106062303.GA12860@cs.duke.edu> +X-Mailer: Apple Mail (2.915) +X-Provags-ID: V01U2FsdGVkX1+U2upB6j5zBd5UJpAi32pjepkqEt+f2EUVXLk + 4xDmYE1gswRWEpvxtO62gW/Yu3xHjgzpqm+BfgIVmuRIVXzof7 + YHAIOIdRdjxlxATKGndHQ== +Status: RO +Content-Length: 357 +Lines: 12 + +I propably found the error: + +According to /usr/lib/python2.5/_strptime.py, '%Z' is restricted to: +[mirko@borg mercurial-crew]$ python -c 'import _strptime; print +_strptime.TimeRE()["Z"]' +(?P<Z>cest|utc|cet|gmt) + +This is propably only true for my local timezone as is EST for +yours :-). Switching to numeric timezones should do the trick. + +Regards +Mirko + +From mirko@friedenhagen.de Mon Jan 7 16:31:41 2008 +Return-Path: <mirko@friedenhagen.de> +X-Spam-Checker-Version: SpamAssassin 3.2.2 (2007-07-23) on one.cs.duke.edu +X-Spam-Level: +X-Spam-Status: No, score=-2.2 required=5.0 tests=AWL,BAYES_00 autolearn=ham + version=3.2.2 +Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.177]) + by one.cs.duke.edu (8.14.0/8.14.0) with ESMTP id m07LVeM0025030 + for <morozov@cs.duke.edu>; Mon, 7 Jan 2008 16:31:41 -0500 (EST) +Received: from borg.local (HSI-KBW-085-216-123-176.hsi.kabelbw.de [85.216.123.176]) + by mrelayeu.kundenserver.de (node=mrelayeu3) with ESMTP (Nemesis) + id 0MKxQS-1JBzZH0fuC-0005IG; Mon, 07 Jan 2008 22:31:35 +0100 +Message-Id: <2DBEA693-A27E-40AC-8823-B1A34B9A9A15@friedenhagen.de> +From: Mirko Friedenhagen <mirko@friedenhagen.de> +To: Dmitriy Morozov <morozov@cs.duke.edu> +In-Reply-To: <20080106062303.GA12860@cs.duke.edu> +Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes +Content-Transfer-Encoding: 7bit +Mime-Version: 1.0 (Apple Message framework v915) +Subject: Re: hg ishow fails in clone of Artemis-repo +Date: Mon, 07 Jan 2008 22:31:33 +0100 +References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> <20080104233436.GA1930@cs.duke.edu> <312C0172-3EF2-488A-A993-CF56C183F9A0@friedenhagen.de> <20080105124708.GA7043@cs.duke.edu> <8B223BED-8A46-4129-A4F3-76B50A890874@friedenhagen.de> <20080106054557.GA12219@cs.duke.edu> <20080106054630.GB12219@cs.duke.edu> <20080106062303.GA12860@cs.duke.edu> +X-Mailer: Apple Mail (2.915) +X-Provags-ID: V01U2FsdGVkX19o42Jm2/riqN1HqzwFbS0PWATW9585MzhlPx4 + nqNci/NQIPJL26EJ9q3ok9stQ9Ydm/zHoAGeVyF7JabTf7Ex5I + kv+DcoQ6Zh8mmw9XDGSOw== +Status: RO +Content-Length: 496 +Lines: 13 + +Last one: + +[mirko@borg mercurial-crew]$ grep -A3 Z /usr/lib/python2.5/_strptime.py + replacement_pairs.extend([(tz, "%Z") for tz_values in +self.timezone + for tz in tz_values]) + for offset,directive in ((0,'%c'), (1,'%x'), (2,'%X')): + current_format = date_time[offset] +-- + 'Z': self.__seqToRE((tz for tz_names in +self.locale_time.timezone + for tz in tz_names), +... + + +From artemis Tue Jan 8 18:28:21 2008 +From: Dmitriy Morozov <morozov@cs.duke.edu> +Date: Tue, 08 Jan 2008 13:28:21 -0500 +Subject: properties changes (state) +Message-Id: <c568146d3275c22b-8f211e40531795e1-artemis@metatron> +References: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> +In-Reply-To: <D08973FE-D4D3-471D-A0E3-4CE2C4C4677F@friedenhagen.de> + +state=fixed diff -r e78a97664dba -r e5b03298394e .issues/ef1b616f31345634 --- a/.issues/ef1b616f31345634 Sun Jan 06 01:18:02 2008 -0500 +++ b/.issues/ef1b616f31345634 Tue Jan 08 13:33:48 2008 -0500 @@ -1,6 +1,6 @@ From artemis Sat Dec 29 21:16:55 2007 From: Dmitriy Morozov <morozov@cs.duke.edu> -Date: Sat, 29 Dec 2007 16:12:43 EST +Date: Sat, 29 Dec 2007 16:12:43 -0500 State: new Subject: intergration with commit Message-Id: <ef1b616f31345634-0-artemis@metatron> diff -r e78a97664dba -r e5b03298394e artemis.py --- a/artemis.py Sun Jan 06 01:18:02 2008 -0500 +++ b/artemis.py Tue Jan 08 13:33:48 2008 -0500 @@ -11,7 +11,7 @@ state['default'] = state['new'] issues_dir = ".issues" filter_prefix = ".filter" -date_format = '%a, %d %b %Y %H:%M:%S %Z' +date_format = '%a, %d %b %Y %H:%M:%S' def ilist(ui, repo, **opts): @@ -50,7 +50,7 @@ if not show_all and (not properties or not property_match) and (properties or mbox[0]['State'].upper() == state['fixed'].upper()): continue - if match_date and not date_match(util.parsedate(mbox[0]['date'], [date_format])[0]): continue + if match_date and not date_match(util.parsedate(mbox[0]['date'])[0]): continue ui.write("%s (%d) [%s]: %s\n" % (issue[len(issues_path)+1:], # +1 for trailing / len(mbox)-1, # number of replies (-1 for self) mbox[0]['State'], @@ -74,7 +74,7 @@ user = ui.username() - default_issue_text = "From: %s\nDate: %s\n" % (user, time.strftime(date_format)) + default_issue_text = "From: %s\nDate: %s\n" % (user, util.datestr(format = date_format)) if not id: default_issue_text += "State: %s\n" % state['default'] default_issue_text += "Subject: brief description\n\n" @@ -160,7 +160,7 @@ if properties and not opts['no_property_comment']: user = ui.username() properties_text = "From: %s\nDate: %s\nSubject: properties changes (%s)\n\n%s" % \ - (user, time.strftime(date_format), + (user, util.datestr(format = date_format), _pretty_list(list(set([property for property, value in properties]))), properties_text) msg = mailbox.mboxMessage(properties_text)