[GitHub] [spark] cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets
cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets URL: https://github.com/apache/spark/pull/28001#discussion_r397589266 ## File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/util/DateTimeTestUtils.scala ## @@ -22,20 +22,31 @@ import java.util.TimeZone import java.util.concurrent.TimeUnit import org.apache.spark.sql.catalyst.util.DateTimeConstants._ +import org.apache.spark.sql.catalyst.util.DateTimeUtils.getZoneId /** * Helper functions for testing date and time functionality. */ object DateTimeTestUtils { + val CEST = getZoneId("+02:00") + val CET = getZoneId("+01:00") + val JST = getZoneId("+09:00") Review comment: if 3 letter short name is ambiguous, shall we pick a clear name like `JAPAN_ZONE`? This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets
cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets URL: https://github.com/apache/spark/pull/28001#discussion_r397588337 ## File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/csv/CSVInferSchemaSuite.scala ## @@ -22,13 +22,15 @@ import java.util.Locale import org.apache.spark.SparkFunSuite import org.apache.spark.sql.catalyst.plans.SQLHelper +import org.apache.spark.sql.catalyst.util.DateTimeTestUtils.UTC import org.apache.spark.sql.internal.SQLConf import org.apache.spark.sql.types._ class CSVInferSchemaSuite extends SparkFunSuite with SQLHelper { test("String fields types are inferred correctly from null types") { -val options = new CSVOptions(Map("timestampFormat" -> "-MM-dd HH:mm:ss"), false, "GMT") Review comment: I think `UTC` is fine as it's a well known standard base timezone. Maybe just replace `GMT` with `UTC`? This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets
cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets URL: https://github.com/apache/spark/pull/28001#discussion_r397588337 ## File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/csv/CSVInferSchemaSuite.scala ## @@ -22,13 +22,15 @@ import java.util.Locale import org.apache.spark.SparkFunSuite import org.apache.spark.sql.catalyst.plans.SQLHelper +import org.apache.spark.sql.catalyst.util.DateTimeTestUtils.UTC import org.apache.spark.sql.internal.SQLConf import org.apache.spark.sql.types._ class CSVInferSchemaSuite extends SparkFunSuite with SQLHelper { test("String fields types are inferred correctly from null types") { -val options = new CSVOptions(Map("timestampFormat" -> "-MM-dd HH:mm:ss"), false, "GMT") Review comment: I think `UTC` is fine as it's well known standard base timezone. Maybe just replace `GMT` with `UTC`? This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org
[GitHub] [spark] cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets
cloud-fan commented on a change in pull request #28001: [SPARK-31237][SQL][TESTS] Replace 3-letter time zones by zone offsets URL: https://github.com/apache/spark/pull/28001#discussion_r397588337 ## File path: sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/csv/CSVInferSchemaSuite.scala ## @@ -22,13 +22,15 @@ import java.util.Locale import org.apache.spark.SparkFunSuite import org.apache.spark.sql.catalyst.plans.SQLHelper +import org.apache.spark.sql.catalyst.util.DateTimeTestUtils.UTC import org.apache.spark.sql.internal.SQLConf import org.apache.spark.sql.types._ class CSVInferSchemaSuite extends SparkFunSuite with SQLHelper { test("String fields types are inferred correctly from null types") { -val options = new CSVOptions(Map("timestampFormat" -> "-MM-dd HH:mm:ss"), false, "GMT") Review comment: I think `UTC` and `GMT` are fine as they are well known standard base timezone. This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services - To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org