Repository navigation
Add index.bin serializer and InvalidIndexBinError - #12
Merged
Merged
Conversation
Add the write side of the index.bin format. It is the twin of the parser in tile_provider::tarball. - TileIndexBinEntry::new and the read path in TarballTileProvider::new use the same checks: the feature index and reserved bits must be zero, and the offset must be a non-zero multiple of 512. - serialize_index_bin changes a non-empty slice of entries into bytes without a copy. A proptest round trip and a byte-for-byte test against the fixture from official Valhalla tooling make sure that the output always parses back into the same entries. - A new InvalidIndexBinError gives the cause of each index failure. GraphTileProviderError wraps it in the new InvalidIndexBin variant. Index failures are no longer InvalidTarball strings. - parse_index_bin no longer has an assert that can panic. - tile_provider re-exports parse_index_bin, serialize_index_bin, TileIndexBinEntry, and InvalidIndexBinError as public items. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
|
I think we just hit the github runner timeout due to the new tests 😂 I'll revisit that later, but I think it's fine to merge. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add the write side of the index.bin format. It is the twin of the parser in tile_provider::tarball.