Skip to content

header checksum and Schema Extension frame added separately #341

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

Merged
merged 3 commits into from
Jun 19, 2025

Conversation

Krmjn09
Copy link
Collaborator

@Krmjn09 Krmjn09 commented Jun 18, 2025

No description provided.

@linev linev requested a review from silverweed June 18, 2025 16:18
@Krmjn09 Krmjn09 requested a review from linev June 18, 2025 16:18
@Krmjn09 Krmjn09 changed the base branch from master to dev June 18, 2025 16:19
@Krmjn09
Copy link
Collaborator Author

Krmjn09 commented Jun 18, 2025

image
in rntuple_test.js these functions directly call field and column descriptor of footer and gives answer 0 for footer which is correct but can i call them for header instead of footer

@@ -148,7 +149,7 @@ deserializeFooter(footer_blob) {
// Feature flag(32 bits)
this._readFeatureFlags(reader);
// Header checksum (64-bit xxhash3)
this.headerChecksum = reader.readU64();
this.headerChecksumFromFooter = reader.readU64();
Copy link
Contributor

Choose a reason for hiding this comment

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

The check on headerChecksumFromFooter === headerEnvelopeChecksum should happen here rather than in the test, as if it fails the RNTuple is corrupted and the reader should stop and report error.

Copy link
Contributor

Choose a reason for hiding this comment

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

(also, this can be a local variable)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

ok

@@ -180,6 +178,14 @@ _readEnvelopeMetadata(reader) {
return { envelopeType, envelopeLength };
}

_readSchemaExtension(reader) {
this._readFieldDescriptors(reader);
Copy link
Contributor

Choose a reason for hiding this comment

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

Be careful: since in _readFieldDescriptors and _readColumnDescriptors you are doing this.fieldDescriptors = fieldDescriptors and similar, every time you call this function you will overwrite the previous ones.
You should either append to the existing array or return that array and handle it on the caller side.
Same goes for _readAliasColumns and _readExtraTypeInformation.

The Footer's schema description should be merged with the Header's to form the complete schema description (most of the time the Footer's schema extension will be empty btw).

@@ -180,6 +178,14 @@ _readEnvelopeMetadata(reader) {
return { envelopeType, envelopeLength };
}

_readSchemaExtension(reader) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
_readSchemaExtension(reader) {
_readSchemaDescription(reader) {

@Krmjn09
Copy link
Collaborator Author

Krmjn09 commented Jun 19, 2025

@silverweed please again check the PR #341 I have done the suggested changes

@Krmjn09
Copy link
Collaborator Author

Krmjn09 commented Jun 19, 2025

image
Got the combined results of header and footer now which is correct

Copy link
Contributor

@silverweed silverweed left a comment

Choose a reason for hiding this comment

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

Thanks! Now you should be able to start deserializing the Page List inside each Cluster Group (you should only have 1 cluster group for most RNTuples)

@Krmjn09
Copy link
Collaborator Author

Krmjn09 commented Jun 19, 2025

Thanks! Now you should be able to start deserializing the Page List inside each Cluster Group (you should only have 1 cluster group for most RNTuples)

For that I have started implementation in a separate PR #342 ,kindly please check that pr and please provide help with its entry point

@Krmjn09
Copy link
Collaborator Author

Krmjn09 commented Jun 19, 2025

@silverweed please merge this pr

@silverweed silverweed merged commit f5eba55 into root-project:dev Jun 19, 2025
24 checks 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