GNU bug report logs - #26902
date: improve error messages for invalid dates

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: coreutils; Severity: wishlist; Reported by: 積丹尼 Dan Jacobson <jidanni@HIDDEN>; dated Fri, 12 May 2017 22:42:01 UTC; Maintainer for coreutils is bug-coreutils@HIDDEN.

Message received at 26902 <at> debbugs.gnu.org:


Received: (at 26902) by debbugs.gnu.org; 31 Dec 2018 06:25:13 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Dec 31 01:25:13 2018
Received: from localhost ([127.0.0.1]:42789 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1gdr0j-0006n5-Gx
	for submit <at> debbugs.gnu.org; Mon, 31 Dec 2018 01:25:13 -0500
Received: from ladybird.maple.relay.mailchannels.net ([23.83.214.98]:18808)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jidanni@HIDDEN>) id 1gdr0g-0006mw-VD
 for 26902 <at> debbugs.gnu.org; Mon, 31 Dec 2018 01:25:12 -0500
X-Sender-Id: dreamhost|x-authsender|jidanni@HIDDEN
Received: from relay.mailchannels.net (localhost [127.0.0.1])
 by relay.mailchannels.net (Postfix) with ESMTP id 3E98C5C3D5C;
 Mon, 31 Dec 2018 06:25:09 +0000 (UTC)
Received: from pdx1-sub0-mail-a40.g.dreamhost.com (unknown [100.96.35.77])
 (Authenticated sender: dreamhost)
 by relay.mailchannels.net (Postfix) with ESMTPA id 5DABE5C3D63;
 Mon, 31 Dec 2018 06:25:07 +0000 (UTC)
X-Sender-Id: dreamhost|x-authsender|jidanni@HIDDEN
Received: from pdx1-sub0-mail-a40.g.dreamhost.com (pop.dreamhost.com
 [64.90.62.162]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384)
 by 0.0.0.0:2500 (trex/5.16.2); Mon, 31 Dec 2018 06:25:09 +0000
X-MC-Relay: Neutral
X-MailChannels-SenderId: dreamhost|x-authsender|jidanni@HIDDEN
X-MailChannels-Auth-Id: dreamhost
X-Ski-Reign: 7b1d31496e3404fa_1546237507496_2301951619
X-MC-Loop-Signature: 1546237507495:1645866815
X-MC-Ingress-Time: 1546237507495
Received: from pdx1-sub0-mail-a40.g.dreamhost.com (localhost [127.0.0.1])
 by pdx1-sub0-mail-a40.g.dreamhost.com (Postfix) with ESMTP id C2A7381C75;
 Sun, 30 Dec 2018 22:25:06 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to:cc
 :subject:references:date:message-id:mime-version:content-type;
 s=jidanni.org; bh=SPdarUHdxxdTASeSdz/F1lpxcPk=; b=J+tFffulSW1fX
 kLN+kOTZa9h+7x75pOlX9jMRVv1Ns4LXK2kz+mk8dGhTS/Hy4CXQpYmaigsGrVoG
 SHmYyWPBWs0FTBIknpgiKXJA5iB5fivtWifavtjsS7cKKJvlf3eFylmqvFEnX/nn
 xnzQPwGx6oNS+nOEaWBJyyZVffinmk=
Received: from jidanni.org (39-9-13-21.adsl.fetnet.net [39.9.13.21])
 (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
 (No client certificate requested)
 (Authenticated sender: jidanni@HIDDEN)
 by pdx1-sub0-mail-a40.g.dreamhost.com (Postfix) with ESMTPSA id 194598041C;
 Sun, 30 Dec 2018 22:25:06 -0800 (PST)
X-DH-BACKEND: pdx1-sub0-mail-a40
From: =?utf-8?B?56mN5Li55bC8?= Dan Jacobson <jidanni@HIDDEN>
To: Assaf Gordon <assafgordon@HIDDEN>
Subject: Re: bug#26902: good invalid dates vs. bad invalid dates
References: <87o9uyhtpi.fsf@HIDDEN>
 <12eb4bba-30cf-dada-12d2-aa69bce31a3c@HIDDEN>
Date: Mon, 31 Dec 2018 14:24:57 +0800
Message-ID: <87imzaxlfq.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain
X-VR-OUT-STATUS: OK
X-VR-OUT-SCORE: -100
X-VR-OUT-SPAMCAUSE: gggruggvucftvghtrhhoucdtuddrgedtledruddugdeliecutefuodetggdotefrodftvfcurfhrohhfihhlvgemucggtfgfnhhsuhgsshgtrhhisggvpdfftffgtefojffquffvnecuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenucfjughrpefhvffufhffkfggtgesthdtredttddtjeenucfhrhhomhepnjjnnjcuffgrnhculfgrtghosghsohhnuceojhhiuggrnhhnihesjhhiuggrnhhnihdrohhrgheqnecukfhppeefledrledrudefrddvudenucfrrghrrghmpehmohguvgepshhmthhppdhhvghlohepjhhiuggrnhhnihdrohhrghdpihhnvghtpeefledrledrudefrddvuddprhgvthhurhhnqdhprghthheppeeruhhtfhdqkeerueerheeimhfphefnihehhegsveekreepucffrghnucflrggtohgsshhonhcuoehjihgurghnnhhisehjihgurghnnhhirdhorhhgqedpmhgrihhlfhhrohhmpehjihgurghnnhhisehjihgurghnnhhirdhorhhgpdhnrhgtphhtthhopedvieeltddvseguvggssghughhsrdhgnhhurdhorhhgnecuvehluhhsthgvrhfuihiivgeptd
X-Spam-Score: 0.1 (/)
X-Debbugs-Envelope-To: 26902
Cc: 26902 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.9 (/)

Maybe it should try to pass on to the user at least an error code:
Invalid date: error code 0754,
or even better, an mention of what error it hit.




Information forwarded to bug-coreutils@HIDDEN:
bug#26902; Package coreutils. Full text available.

Message received at 26902 <at> debbugs.gnu.org:


Received: (at 26902) by debbugs.gnu.org; 31 Dec 2018 05:22:15 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Mon Dec 31 00:22:15 2018
Received: from localhost ([127.0.0.1]:42763 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1gdq1n-00038R-2z
	for submit <at> debbugs.gnu.org; Mon, 31 Dec 2018 00:22:15 -0500
Received: from mail-pf1-f174.google.com ([209.85.210.174]:38483)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <assafgordon@HIDDEN>) id 1gdq1l-00038D-Hs
 for 26902 <at> debbugs.gnu.org; Mon, 31 Dec 2018 00:22:13 -0500
Received: by mail-pf1-f174.google.com with SMTP id q1so12841815pfi.5
 for <26902 <at> debbugs.gnu.org>; Sun, 30 Dec 2018 21:22:13 -0800 (PST)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025;
 h=subject:to:references:from:message-id:date:user-agent:mime-version
 :in-reply-to:content-language:content-transfer-encoding;
 bh=0SXGqQfK4ApKchGgATZUUzN36S1WhImwhpiEjA16RS8=;
 b=YNCOMfO1zxTyCUGKx1dono93oUoDctD1WKYqb9L9KQrKmBckhW86y2QoYo45vnJMzS
 XocDjo5Ao3SA3GYVW7psbkzYxZ2eE05bFS/sGVvfxD8NljW9+YtPKXUZCklqZSOm6Sep
 bFPP2Ix+i5p/Rb3AbHqRlM4qAolKlRx4E73Pp039j5YuxF7hI/O9JFdppBVMePHRqw3s
 EtWzxwhNFVX5CslKETX40uabcLqQLxI/oYuBysyBrIPbbh3qgEuv/9liDtjoS/L9Sgxv
 hwJSxEOOHZdzMS9v8/jkNAd4Q6RTG8ityHRN+KJ9wygskSMte3zkj/WxQp9cNU/JK5Rv
 BBPg==
X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
 d=1e100.net; s=20161025;
 h=x-gm-message-state:subject:to:references:from:message-id:date
 :user-agent:mime-version:in-reply-to:content-language
 :content-transfer-encoding;
 bh=0SXGqQfK4ApKchGgATZUUzN36S1WhImwhpiEjA16RS8=;
 b=iWdjMr2DeHWxy692fcO2vb3hMcGlERNECySf5MKdtP7zhgCJj0Yjdw0OzcQUPa6Nsj
 KrYIQkAUAo8ecLxJtQleapwtnGGUzTHiuLnxiSWohteXR7sUIxJ9qtqy/zRnSLm5tCzt
 Qo9vI4sB+5z5DIQ7FlqFFOXZ6ZVXBIPpeqBJ282T9o6KhQLT5DF9aGK1u3I6Rew9aomL
 2FxWDJ0GXX08rslqZhYuMH+n3k5HwM9zwlT5wUoAj9adaXfPZl2bTzQh+ANOmEv3t1xp
 jOVP3ABTkjNbfBHQb2r+PaSRMP4d+04o/P+kV5kB2uq08TvW0HA9RsRlf1BIobnEUrtK
 Y7Uw==
X-Gm-Message-State: AA+aEWY1MHuRQCrFaEZko4sBds1R8oymIWwyTlxoJFSsL9qD0LizanTU
 BwZkO5+2QjbHFKoEF3SFoNq6n86u
X-Google-Smtp-Source: AFSGD/Uhg6hje5izqY2XNeudkokINzW1lU9r5aYfF6xSuPcLIQXWvU+7jQBvZUye3++z0leSPKqz7A==
X-Received: by 2002:a62:6799:: with SMTP id t25mr36844768pfj.139.1546233727159; 
 Sun, 30 Dec 2018 21:22:07 -0800 (PST)
Received: from tomato.housegordon.com (moose.housegordon.com. [184.68.105.38])
 by smtp.googlemail.com with ESMTPSA id
 z9sm135261914pfd.99.2018.12.30.21.22.05
 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
 Sun, 30 Dec 2018 21:22:05 -0800 (PST)
Subject: Re: bug#26902: good invalid dates vs. bad invalid dates
To: =?UTF-8?B?56mN5Li55bC8IERhbiBKYWNvYnNvbg==?= <jidanni@HIDDEN>,
 26902 <at> debbugs.gnu.org
References: <87o9uyhtpi.fsf@HIDDEN>
From: Assaf Gordon <assafgordon@HIDDEN>
Message-ID: <12eb4bba-30cf-dada-12d2-aa69bce31a3c@HIDDEN>
Date: Sun, 30 Dec 2018 22:22:04 -0700
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101
 Thunderbird/60.3.0
MIME-Version: 1.0
In-Reply-To: <87o9uyhtpi.fsf@HIDDEN>
Content-Type: text/plain; charset=utf-8; format=flowed
Content-Language: en-US
Content-Transfer-Encoding: 8bit
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 26902
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Hello,

On 2017-05-12 11:26 a.m., 積丹尼 Dan Jacobson wrote:
> Can you please don't say "invalid date" for everything invalid.
> 
> $ date -d @1494439601675485
> date: invalid date ‘@1494439601675485’
> $ date -d 1494439601675485sec
> date: invalid date ‘1494439601675485sec’
> $ date -d 1494439601675485seconds
> date: invalid date ‘1494439601675485seconds’
> $ date -d @1494439601675485
> date: invalid date ‘@1494439601675485’
> $ date -d @1494439601675
> date: invalid date ‘@1494439601675’
> $ date -d @1
> 四  1月  1 08:00:01 CST 1970
> $ date -d @149443960167
> date: invalid date ‘@149443960167’
> $ date -d @14944396016
> date: invalid date ‘@14944396016’
> $ date -d @1494439601
> 四  5月 11 02:06:41 CST 2017
> $ date -d @zzzzzz
> date: invalid date ‘@zzzzzz’
> 
> On (info "(coreutils) Seconds since the Epoch") it says
> 
>        Traditional Unix systems count seconds with 32-bit two’s-complement
>     integers and can represent times from 1901-12-13 20:45:52 through
>     2038-01-19 03:14:07 UTC.  More modern systems use 64-bit counts of
>     seconds with nanosecond subcounts, and can represent all the times in
> 
> Please catch the cases where the user merely has entered too many digits
> for the computer in question, and say
> date: too far into the future.
> or
> date: too far into the future for current computer.
> or
> date: invalid date: too far into the future for current computer.
> 
> Please don't just give the same message that you give if the user hasn't
> even entered one digit.

Please note that the errors above (with "@") are specific to 32-bit system,
where "time_t" is a signed 32 bit integer (and thus limited to
2147483647, the infamous "Year 2038" problem).

On a 64-bit system, the range is larger (allowing dates into the far
future), and too-far values are reported:

   $ date -d @2147483647
   Mon Jan 18 20:14:07 MST 2038
   $ date -d @2147483648
   Mon Jan 18 20:14:08 MST 2038
   $ date -d @214748364800
   Sat Feb  8 04:33:20 MST 8775
   $ date -d @21474836480000
   Sat Jun 22 21:33:20 MDT 682480
   $ date -d @2147483648000000
   Wed Oct  8 12:33:20 MST 68053017
   $ date -d @214748364800000000
   date: time ‘214748364800000000’ is out of range


I'm thus inclined to close this as "wontfix", but others opinions
are welcomed.


regards,
  - assaf


P.S.
If anyone is interested in trying their hands at a patch:

The "invalid date" error originates from the
bison-generated parser indicating a parsing problem, not directly
an "integer too large" problem (a call to YYABORT in gnulib's 
"parse-datetime.y).

A good place to start is the "seconds" parsing rule here:

   https://git.sv.gnu.org/cgit/gnulib.git/tree/lib/parse-datetime.y#n968

Both "signed_seconds" and "unsigned_seconds" rules have the following
condition:

     if (time_overflow ($1.value)) YYABORT;

Instead of "YYABORT" another error mechanism could be created.




Information forwarded to bug-coreutils@HIDDEN:
bug#26902; Package coreutils. Full text available.
Changed bug title to 'date: improve error messages for invalid dates' from 'good invalid dates vs. bad invalid dates' Request was from Assaf Gordon <assafgordon@HIDDEN> to control <at> debbugs.gnu.org. Full text available.
Severity set to 'wishlist' from 'normal' Request was from Assaf Gordon <assafgordon@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 12 May 2017 22:41:09 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Fri May 12 18:41:09 2017
Received: from localhost ([127.0.0.1]:41443 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1d9JFE-0005g2-Sr
	for submit <at> debbugs.gnu.org; Fri, 12 May 2017 18:41:09 -0400
Received: from eggs.gnu.org ([208.118.235.92]:59887)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <jidanni@HIDDEN>) id 1d9JFC-0005fm-QW
 for submit <at> debbugs.gnu.org; Fri, 12 May 2017 18:41:07 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <jidanni@HIDDEN>) id 1d9JF6-0004gw-Pl
 for submit <at> debbugs.gnu.org; Fri, 12 May 2017 18:41:01 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: **
X-Spam-Status: No, score=2.4 required=5.0 tests=BAYES_50,DATE_IN_PAST_03_06,
 T_DKIM_INVALID autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:55128)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <jidanni@HIDDEN>) id 1d9JF6-0004gK-Hu
 for submit <at> debbugs.gnu.org; Fri, 12 May 2017 18:41:00 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:50851)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <jidanni@HIDDEN>) id 1d9JF5-0002Jk-8L
 for bug-coreutils@HIDDEN; Fri, 12 May 2017 18:41:00 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <jidanni@HIDDEN>) id 1d9JF1-0004Xq-9a
 for bug-coreutils@HIDDEN; Fri, 12 May 2017 18:40:59 -0400
Received: from homie.mail.dreamhost.com ([208.97.132.208]:51944
 helo=homiemail-a7.g.dreamhost.com)
 by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <jidanni@HIDDEN>) id 1d9JF1-0004Vp-01
 for bug-coreutils@HIDDEN; Fri, 12 May 2017 18:40:55 -0400
Received: from homiemail-a7.g.dreamhost.com (localhost [127.0.0.1])
 by homiemail-a7.g.dreamhost.com (Postfix) with ESMTP id 0027525C06A
 for <bug-coreutils@HIDDEN>; Fri, 12 May 2017 15:40:51 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to
 :subject:date:message-id:mime-version:content-type:
 content-transfer-encoding; s=jidanni.org; bh=YnwwEnkgJm8sjfqMdhN
 VQUYvRW4=; b=hcL7zYhMtuxfvYTCY9104NuKR9mbzTPKTZcEPqFn6Sar+yoIdQQ
 BJXhbw/90L/sIe3csLSpAF/SCZzrcHvbcR/bx8BYAjlNXWCiD5h1y98ePd+tTP0i
 YgbZHkhVyYj2mPuSxDkMzjpavytYiAa/ELGidaPfUJrsIUfJRuwc1+FI=
Received: from jidanni.org (122-118-149-227.dynamic-ip.hinet.net
 [122.118.149.227])
 (using TLSv1 with cipher AES256-SHA (256/256 bits))
 (No client certificate requested)
 (Authenticated sender: jidanni@HIDDEN)
 by homiemail-a7.g.dreamhost.com (Postfix) with ESMTPSA id 77EEC25C062
 for <bug-coreutils@HIDDEN>; Fri, 12 May 2017 15:40:51 -0700 (PDT)
From: =?utf-8?B?56mN5Li55bC8?= Dan Jacobson <jidanni@HIDDEN>
To: bug-coreutils@HIDDEN
Subject: good invalid dates vs. bad invalid dates
Date: Sat, 13 May 2017 01:26:49 +0800
Message-ID: <87o9uyhtpi.fsf@HIDDEN>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: quoted-printable
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x [fuzzy]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: -3.9 (---)
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -3.9 (---)

Can you please don't say "invalid date" for everything invalid.

$ date -d @1494439601675485
date: invalid date =E2=80=98@1494439601675485=E2=80=99
$ date -d 1494439601675485sec
date: invalid date =E2=80=981494439601675485sec=E2=80=99
$ date -d 1494439601675485seconds
date: invalid date =E2=80=981494439601675485seconds=E2=80=99
$ date -d @1494439601675485
date: invalid date =E2=80=98@1494439601675485=E2=80=99
$ date -d @1494439601675
date: invalid date =E2=80=98@1494439601675=E2=80=99
$ date -d @1
=E5=9B=9B  1=E6=9C=88  1 08:00:01 CST 1970
$ date -d @149443960167
date: invalid date =E2=80=98@149443960167=E2=80=99
$ date -d @14944396016
date: invalid date =E2=80=98@14944396016=E2=80=99
$ date -d @1494439601
=E5=9B=9B  5=E6=9C=88 11 02:06:41 CST 2017
$ date -d @zzzzzz
date: invalid date =E2=80=98@zzzzzz=E2=80=99

On (info "(coreutils) Seconds since the Epoch") it says

      Traditional Unix systems count seconds with 32-bit two=E2=80=99s-co=
mplement
   integers and can represent times from 1901-12-13 20:45:52 through
   2038-01-19 03:14:07 UTC.  More modern systems use 64-bit counts of
   seconds with nanosecond subcounts, and can represent all the times in

Please catch the cases where the user merely has entered too many digits
for the computer in question, and say
date: too far into the future.
or
date: too far into the future for current computer.
or
date: invalid date: too far into the future for current computer.

Please don't just give the same message that you give if the user hasn't
even entered one digit.




Acknowledgement sent to 積丹尼 Dan Jacobson <jidanni@HIDDEN>:
New bug report received and forwarded. Copy sent to bug-coreutils@HIDDEN. Full text available.
Report forwarded to bug-coreutils@HIDDEN:
bug#26902; Package coreutils. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 31 Dec 2018 06:30:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.