Skip to content

[Bug] DataFrame.toJson() does not recognize array columns correctly #2046

Description

@Jolanrensen

Related to #2045

DataFrame.readJsonStr("""[{"label":"record"},[123]]""")

turn into

       label      array
     String?  List<Int>
        ----       ----
  0   record        [ ]
  1     null      [123]

while the array-column detection of toJson() does not correctly mark array as an array-column; it assumes the values in the array column must be null when other columns have values.
So we get:

df.toJson()
[{"label":"record","array":[]},{"label":null,"array":[123]}]

Expected behavior is to have it return to its original state.

Should be solved together with #2048

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

bugSomething isn't working

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions