[ 
https://issues.apache.org/jira/browse/SPARK-15723?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Sean Owen resolved SPARK-15723.
-------------------------------
       Resolution: Fixed
         Assignee: Brett Randall
    Fix Version/s: 2.0.0
                   1.6.2

Resolved by https://github.com/apache/spark/pull/13462

> SimpleDateParamSuite test is locale-fragile and relies on deprecated short TZ 
> name
> ----------------------------------------------------------------------------------
>
>                 Key: SPARK-15723
>                 URL: https://issues.apache.org/jira/browse/SPARK-15723
>             Project: Spark
>          Issue Type: Bug
>          Components: Spark Core
>    Affects Versions: 1.6.1
>            Reporter: Brett Randall
>            Assignee: Brett Randall
>            Priority: Minor
>              Labels: test
>             Fix For: 1.6.2, 2.0.0
>
>
> {{org.apache.spark.status.api.v1.SimpleDateParamSuite}} has this assertion:
> {code}
>     new SimpleDateParam("2015-02-20T17:21:17.190EST").timestamp should be 
> (1424470877190L)
> {code}
> This test is fragile and fails when executing in an environment where the 
> local default timezone causes {{EST}} to be interpreted as something other 
> than US Eastern Standard Time.  If your local timezone is 
> {{Australia/Sydney}}, then {{EST}} equates to {{GMT+10}} and you will get:
> {noformat}
> date parsing *** FAILED ***
> 1424413277190 was not equal to 1424470877190 (SimpleDateParamSuite.scala:29)
> {noformat}
> In short, {{SimpleDateFormat}} is sensitive to the local default {{TimeZone}} 
> when interpreting short zone names.  According to the {{TimeZone}} javadoc, 
> they ought not be used:
> {quote}
> Three-letter time zone IDs
> For compatibility with JDK 1.1.x, some other three-letter time zone IDs (such 
> as "PST", "CTT", "AST") are also supported. However, their use is deprecated 
> because the same abbreviation is often used for multiple time zones (for 
> example, "CST" could be U.S. "Central Standard Time" and "China Standard 
> Time"), and the Java platform can then only recognize one of them.
> {quote}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@spark.apache.org
For additional commands, e-mail: issues-h...@spark.apache.org

Reply via email to