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

[Python] Could not read encrypted metadata via pq.read_table #43406

Closed
heyuqi1970 opened this issue Jul 24, 2024 · 4 comments
Closed

[Python] Could not read encrypted metadata via pq.read_table #43406

heyuqi1970 opened this issue Jul 24, 2024 · 4 comments

Comments

@heyuqi1970
Copy link

Describe the bug, including details regarding any error messages, version, and platform.

os: macos 11.7.10 (20G1427)
python: 3.9.7
pyarrow: 16.0.0

when I use pq.read_table with decryption_properties parameter, I get the following error。
And I can use pq.ParquetFile with decryption_properties to read same encrypted file.

Traceback (most recent call last):
  File "tt.py", line 98, in <module>
    table = pq.read_table("yellow_cryp.parquet", memory_map=True, decryption_properties=decryption_properties)
  File "/venv/lib/python3.9/site-packages/pyarrow/parquet/core.py", line 1762, in read_table
    dataset = ParquetDataset(
  File "/venv/lib/python3.9/site-packages/pyarrow/parquet/core.py", line 1329, in __init__
    [fragment], schema=schema or fragment.physical_schema,
  File "pyarrow/_dataset.pyx", line 1431, in pyarrow._dataset.Fragment.physical_schema.__get__
  File "pyarrow/error.pxi", line 154, in pyarrow.lib.pyarrow_internal_check_status
  File "pyarrow/error.pxi", line 91, in pyarrow.lib.check_status
OSError: Could not open Parquet input source 'yellow_cryp.parquet': Could not read encrypted metadata, no decryption found in reader's properties

Component(s)

Parquet, Python

@mapleFU
Copy link
Member

mapleFU commented Jul 24, 2024

@adamreeve @wgtmac do you have some infor for this issue?

@wgtmac
Copy link
Member

wgtmac commented Jul 24, 2024

This error happens when reading a parquet file with encrypted footer without providing decryption properties. From the issue description, it looks like the properties are not properly passed by the python dataset api.

@heyuqi1970 Could you please try the latest 17.0.0 release? If it still happens, please share the code to reproduce it if possible.

cc @tolleybot I'm not sure if you have fixed a similar issue.

@jorisvandenbossche jorisvandenbossche changed the title Could not read encrypted metadata via pq.read_table [Python] Could not read encrypted metadata via pq.read_table Jul 25, 2024
@heyuqi1970
Copy link
Author

@wgtmac
THX, 17.0.0 addresses this issue.

@wgtmac
Copy link
Member

wgtmac commented Jul 27, 2024

Thanks for your confirmation! @heyuqi1970

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

No branches or pull requests

3 participants