Return-Path: X-Original-To: apmail-couchdb-dev-archive@www.apache.org Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id ED092106EF for ; Thu, 17 Apr 2014 18:18:26 +0000 (UTC) Received: (qmail 60926 invoked by uid 500); 17 Apr 2014 18:17:58 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 60569 invoked by uid 500); 17 Apr 2014 18:17:43 -0000 Mailing-List: contact dev-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list dev@couchdb.apache.org Received: (qmail 59813 invoked by uid 99); 17 Apr 2014 18:17:19 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 17 Apr 2014 18:17:19 +0000 Date: Thu, 17 Apr 2014 18:17:19 +0000 (UTC) From: "ASF subversion and git services (JIRA)" To: dev@couchdb.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (COUCHDB-627) badarg caused in UTC+7 timezones MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/COUCHDB-627?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13973227#comment-13973227 ] ASF subversion and git services commented on COUCHDB-627: --------------------------------------------------------- Commit d881aa324fa9be686ac4f6f60a59d86374a4f8ff in couchdb-mochiweb's branch refs/heads/1843-feature-bigcouch from [~rnewson] [ https://git-wip-us.apache.org/repos/asf?p=couchdb-mochiweb.git;h=d881aa3 ] COUCHDB-627 - Support all timezones Some timezones are incorrectly handled by OTP's calendar module. The ironic thing is that we only ever need the time in GMT (for HTTP response headers and the log file). This patch duplicates httpd_util:rfc1123_date/0 and /1 but uses universal time everywhere, avoiding the broken conversion code. > badarg caused in UTC+7 timezones > -------------------------------- > > Key: COUCHDB-627 > URL: https://issues.apache.org/jira/browse/COUCHDB-627 > Project: CouchDB > Issue Type: Bug > Affects Versions: 0.11 > Environment: MacBook Pro, Snow Leopard 10.6.2 > Reporter: Robert Newson > Assignee: Robert Newson > Fix For: 1.3 > > > A user reported problems on IRC. It turns out that couchdb (or mochiweb) barfs when the local machine is set to some timezones. > I set my local timezone to Western Indonesian Time (WIT) and reproduced the bug. > Steps > 1) Change to WIT > 2) Visit Futon > Error; > {"error":"unknown_error","reason":"badarg"} > and logs report; > [info] [<0.104.0>] 127.0.0.1 - - 'GET' /_utils/index.html 500 > [error] [<0.112.0>] Badarg error in HTTP request > [info] [<0.112.0>] Stacktrace: [{erlang,universaltime_to_localtime,[{{1969,12,31},{23,59,59}}]}, > {calendar,local_time_to_universal_time_dst,1}, > {httpd_util,rfc1123_date,1}, > {mochiweb_request,maybe_serve_file,3}, > {couch_httpd,serve_file,4}, > {couch_httpd,handle_request,5}, > {mochiweb_http,headers,5}, > {proc_lib,init_p_do_apply,3}] -- This message was sent by Atlassian JIRA (v6.2#6252)