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

Update index.ts to support RLE_DICTIONARY #112

Merged
merged 2 commits into from
Jan 18, 2024

Conversation

saritvakrat
Copy link

@saritvakrat saritvakrat commented Jan 17, 2024

Problem

problem statement - when trying to read a parquet file that was generated using V2 parquet and had RLE_DICTIONARY, got an error: invalid encoding: RLE_DICTIONARY #96

Reported issue: #96

Solution

What I/we did to solve this problem
added: export * as RLE_DICTIONARY from './plain_dictionary';

with @pairperson1

Change summary:

  • Tidy, well formulated commit message
  • Another great commit message
  • Something else I/we did

Steps to Verify:

I added this line to an existing project in the node modules and it works. without this line I get an an error with this line added - it passed

@@ -1,5 +1,5 @@
export * as PLAIN from './plain'
export * as RLE from './rle'
export * as PLAIN_DICTIONARY from './plain_dictionary'

export * as RLE_DICTIONARY from './plain_dictionary'
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Turns out the plain_dictionary has support for both!

Comment on lines +193 to +194
// Tracked in https://github.com/LibertyDSNP/parquetjs/issues/113
it.skip('rle_boolean_encoding.parquet loads', async function() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added this in a separate issue as it still fails.

Comment on lines 200 to 208
it('rle-dict-snappy-checksum.parquet loads', async function() {
const data = await readData('rle/rle-dict-snappy-checksum.parquet');
assert.deepEqual(data[0],{ binary_field: "c95e263a-f5d4-401f-8107-5ca7146a1f98", long_field: 0 });
});

it('rle-dict-uncompressed-corrupt-checksum.parquet loads', async function() {
const data = await readData('rle/rle-dict-uncompressed-corrupt-checksum.parquet');
assert.deepEqual(data[0],{ binary_field: "6325c32b-f417-41aa-9e02-9b8601542aff", long_field: 0 });
});
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reference files from https://github.com/apache/parquet-testing work!

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@wilwade wilwade merged commit 6fdb9da into LibertyDSNP:main Jan 18, 2024
1 check passed
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

Successfully merging this pull request may close these issues.

2 participants