You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Xiao Li (JIRA)" <ji...@apache.org> on 2018/06/24 00:42:00 UTC
[jira] [Resolved] (SPARK-24190) lineSep shouldn't be required in
JSON write
[ https://issues.apache.org/jira/browse/SPARK-24190?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Xiao Li resolved SPARK-24190.
-----------------------------
Resolution: Fixed
Assignee: Maxim Gekk
Fix Version/s: 2.4.0
> lineSep shouldn't be required in JSON write
> -------------------------------------------
>
> Key: SPARK-24190
> URL: https://issues.apache.org/jira/browse/SPARK-24190
> Project: Spark
> Issue Type: Bug
> Components: SQL
> Affects Versions: 2.3.0
> Reporter: Maxim Gekk
> Assignee: Maxim Gekk
> Priority: Minor
> Fix For: 2.4.0
>
>
> Currently, the lineSep option is required by JSON datasource in write if encoding is different from UTF-8. For example, the code:
> {code:scala}
> df.write.option("encoding", "UTF-32BE").json(file)
> {code}
> throws the exception:
> {code}
> requirement failed: The lineSep option must be specified for the UTF-32BE encoding
> java.lang.IllegalArgumentException: requirement failed: The lineSep option must be specified for the UTF-32BE encoding
> at scala.Predef$.require(Predef.scala:224)
> at org.apache.spark.sql.catalyst.json.JSONOptions$$anonfun$32.apply(JSONOptions.scala:118)
> at org.apache.spark.sql.catalyst.json.JSONOptions$$anonfun$32.apply(JSONOptions.scala:103)
> at scala.Option.map(Option.scala:146)
> {code}
> The restriction should NOT be applied to writing.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org