Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

interoperability with round-tripping through data format broken on latest release (1.4.1) #76

Closed
adienes opened this issue Jun 30, 2024 · 3 comments

Comments

@adienes
Copy link

adienes commented Jun 30, 2024

# julia

julia> Arrow.write("mwe.arrow", Tables.rowtable((; a = String3["xyz", "123"])))
# python

>>> import polars as pl
>>> pl.read_ipc("mwe.arrow")
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/opt/homebrew/lib/python3.11/site-packages/polars/utils/deprecation.py", line 133, in wrapper
    return function(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/polars/utils/deprecation.py", line 133, in wrapper
    return function(*args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/polars/io/ipc/functions.py", line 103, in read_ipc
    return pl.DataFrame._read_ipc(
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/lib/python3.11/site-packages/polars/dataframe/frame.py", line 990, in _read_ipc
    self._df = PyDataFrame.read_ipc(
               ^^^^^^^^^^^^^^^^^^^^^
polars.exceptions.ComputeError: cannot create series from Extension("JuliaLang.InlineStrings.InlineString3", Utf8, Some(""))
@ericphanson
Copy link

ericphanson commented Jul 5, 2024

I created a simple PyArrow.jl wrapper to try to help setup inter-language tests for packages like this. But here I'm getting:

using InlineStrings, Arrow, PyArrow, Tables
const ft = pyimport("pyarrow.feather")

Arrow.write("mwe.arrow", Tables.rowtable((; a = String3["xyz", "123"])))
ft.read_table("mwe.arrow")

gives me:

Python:
pyarrow.Table
a: string not null
----
a: [["xyz","123"]]

which seems fine.

So I wonder if it's a polars issue that they are not ignoring unknown extensions?

@ericphanson
Copy link

hm, looks like it: pola-rs/polars#9112 (comment)

@adienes
Copy link
Author

adienes commented Jul 6, 2024

ah I see. thanks for looking into it --- I'll bump the issue over there

@adienes adienes closed this as completed Jul 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants