Skip to content

Blackrock add block validation #1740

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

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

h-mayorquin
Copy link
Contributor

This is a PR I made when working together @luiztauffer to figure out how to open a malformed file. According to the blackrock spec heach data block has a flag indicating the start of the data block:

image

This PR adds a check and provides detailed debugging information including file offset, block index, expected vs actual values, and corruption indicators.

I also improved the missing file error message which now specifically list which NSX files are missing and did other minor improvements like using f-string formatting for filename
construction, clearer variable naming (replacing ambiguous spec with spec_version and
dh with packet_header), etc.

Copy link
Contributor

@zm711 zm711 left a comment

Choose a reason for hiding this comment

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

This seems fine to me.

Copy link
Contributor

@zm711 zm711 left a comment

Choose a reason for hiding this comment

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

Good by me. I'll wait to see if @samuelgarcia or @alejoe91 want to take a quick look too.

@zm711 zm711 added this to the 0.14.2 milestone Jul 2, 2025
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