[jira] [Updated] (ARROW-15803) [R] Empty JSON object parsed as corrupt data frame

2022-06-30 Thread Jonathan Keane (Jira)


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

Jonathan Keane updated ARROW-15803:
---
Fix Version/s: (was: 9.0.0)

> [R] Empty JSON object parsed as corrupt data frame
> --
>
> Key: ARROW-15803
> URL: https://issues.apache.org/jira/browse/ARROW-15803
> Project: Apache Arrow
>  Issue Type: Bug
>  Components: R
>Affects Versions: 7.0.0
>Reporter: Will Jones
>Priority: Major
>
> If you have a JSON object field that is always empty, it seems to be not 
> handled well, whether or not a schema is provided that tells Arrow what 
> should be in that object.
> {code:r}
> library(arrow)
> #> 
> #> Attaching package: 'arrow'
> #> The following object is masked from 'package:utils':
> #> 
> #> timestamp
> json_val <- '{
>   "rows": [
> {"empty": {} },
> {"empty": {} },
> {"empty": {} }
>   ]
> }'
> # Remove newlines
> json_val <- gsub("\n", "", json_val)
> json_file <- tempfile()
> writeLines(json_val, json_file)
> schema <- schema(field("rows", list_of(struct(empty = struct(y = int32())
> raw <- read_json_arrow(json_file, schema=schema)
> raw$rows$empty
> #> Error: Corrupt x: no names
> {code}



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


[jira] [Updated] (ARROW-15803) [R] Empty JSON object parsed as corrupt data frame

2022-04-13 Thread Will Jones (Jira)


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

Will Jones updated ARROW-15803:
---
Fix Version/s: 9.0.0
   (was: 8.0.0)

> [R] Empty JSON object parsed as corrupt data frame
> --
>
> Key: ARROW-15803
> URL: https://issues.apache.org/jira/browse/ARROW-15803
> Project: Apache Arrow
>  Issue Type: Bug
>  Components: R
>Affects Versions: 7.0.0
>Reporter: Will Jones
>Priority: Major
> Fix For: 9.0.0
>
>
> If you have a JSON object field that is always empty, it seems to be not 
> handled well, whether or not a schema is provided that tells Arrow what 
> should be in that object.
> {code:r}
> library(arrow)
> #> 
> #> Attaching package: 'arrow'
> #> The following object is masked from 'package:utils':
> #> 
> #> timestamp
> json_val <- '{
>   "rows": [
> {"empty": {} },
> {"empty": {} },
> {"empty": {} }
>   ]
> }'
> # Remove newlines
> json_val <- gsub("\n", "", json_val)
> json_file <- tempfile()
> writeLines(json_val, json_file)
> schema <- schema(field("rows", list_of(struct(empty = struct(y = int32())
> raw <- read_json_arrow(json_file, schema=schema)
> raw$rows$empty
> #> Error: Corrupt x: no names
> {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)


[jira] [Updated] (ARROW-15803) [R] Empty JSON object parsed as corrupt data frame

2022-04-08 Thread Jacob Wujciak-Jens (Jira)


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

Jacob Wujciak-Jens updated ARROW-15803:
---
Component/s: R

> [R] Empty JSON object parsed as corrupt data frame
> --
>
> Key: ARROW-15803
> URL: https://issues.apache.org/jira/browse/ARROW-15803
> Project: Apache Arrow
>  Issue Type: Bug
>  Components: R
>Affects Versions: 7.0.0
>Reporter: Will Jones
>Priority: Major
> Fix For: 8.0.0
>
>
> If you have a JSON object field that is always empty, it seems to be not 
> handled well, whether or not a schema is provided that tells Arrow what 
> should be in that object.
> {code:r}
> library(arrow)
> #> 
> #> Attaching package: 'arrow'
> #> The following object is masked from 'package:utils':
> #> 
> #> timestamp
> json_val <- '{
>   "rows": [
> {"empty": {} },
> {"empty": {} },
> {"empty": {} }
>   ]
> }'
> # Remove newlines
> json_val <- gsub("\n", "", json_val)
> json_file <- tempfile()
> writeLines(json_val, json_file)
> schema <- schema(field("rows", list_of(struct(empty = struct(y = int32())
> raw <- read_json_arrow(json_file, schema=schema)
> raw$rows$empty
> #> Error: Corrupt x: no names
> {code}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)