git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chris Packham <judge.packham@gmail.com>
To: git@vger.kernel.org
Subject: Ambiguous date handling
Date: Wed, 12 Sep 2012 21:35:50 +1200	[thread overview]
Message-ID: <1347442551-7105-1-git-send-email-judge.packham@gmail.com> (raw)

Hi,

I think this has come up before [1],[2] but we ran into this at $dayjob today.
Our default MUA has an annoying habit of using a non RFC822 date format when
saving an email as plaintext. This means the first 12 days of every month we
run into the ambiguous date problem (our date convention is dd/mm/yy).

I see code in date.c for refusing a date in the future which would have caught
this but it doesn't appear to be working for us.

Following this is a patch adding a testcase for this. With the following
results:

  ok 1 - apply patch with ambiguous date
  not ok 2 - check ambiguous date # TODO known breakage
  ok 3 - apply patch with european date separator
  ok 4 - check european date
  # still have 1 known breakage(s)
  # passed all remaining 3 test(s)
  1..4

Thanks,
Chris

--
[1] - http://thread.gmane.org/gmane.comp.version-control.git/18412/focus=18417
[2] - http://thread.gmane.org/gmane.comp.version-control.git/84512/focus=85735

             reply	other threads:[~2012-09-12  9:35 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-12  9:35 Chris Packham [this message]
2012-09-12  9:35 ` [PATCH] Add test for ambiguous patch dates Chris Packham
2012-09-12  9:48 ` Ambiguous date handling Junio C Hamano
2012-09-12 10:09   ` Chris Packham
2012-09-12 16:58     ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1347442551-7105-1-git-send-email-judge.packham@gmail.com \
    --to=judge.packham@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).