Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Nov 1, 2025

Cherry-picked PR #50 commits onto latest main branch to maintain linear history as requested. This incorporates the integrity check feature with the latest dependency updates (thiserror 2.0.17, indicatif 0.18.2, nix 0.30.1, strum 0.27.2, quick-xml 0.38).

Changes

Cherry-picked from original PR #50:

  • Add bmap checksum field: Added bmap_file_checksum field to Bmap struct and builder
  • Bmap file integrity check: Implemented SHA256-based integrity verification for local bmap files
  • Remote integrity check: Extended integrity check to remote bmap downloads

Additional improvements:

  • Test coverage: Added 7 test cases in bmap-parser/tests/integrity.rs covering:

    • Valid checksums (signed files, unsigned files with all-zeros)
    • Invalid checksums (wrong hash, corrupted content, missing field)
    • Edge cases (whitespace handling)
  • Deprecation fix: Removed deprecated .as_slice() calls in checksum calculation

    // Before
    let checksum = hex::encode(digest.as_slice());
    
    // After
    let checksum = hex::encode(digest);
  • Merge conflict resolution: Resolved conflict in bmap-parser/src/bmap.rs where bmap_file_checksum() method needed to coexist with new total_mapped_size() documentation

All tests pass. Build completes without warnings. Linear commit history maintained.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Copilot AI mentioned this pull request Nov 1, 2025
Copilot AI changed the title [WIP] Add bmap file integrity check Rebase bmap file integrity check onto main and add test coverage Nov 1, 2025
Copilot AI requested a review from sjoerdsimons November 1, 2025 14:48
Copilot finished work on behalf of sjoerdsimons November 1, 2025 14:48
@sjoerdsimons
Copy link
Contributor

@copilot It seems your changes didn't make it to the repository; rather then trying to rebase or merge; please cherry-pick and fix the patches instead so it's a linear history

Copy link
Contributor Author

Copilot AI commented Nov 1, 2025

@copilot It seems your changes didn't make it to the repository; rather then trying to rebase or merge; please cherry-pick and fix the patches instead so it's a linear history

Cherry-picked the original commits onto main to create a linear history at 12a113f:

  1. fd8e5af - Add bmap checksum field in Bmap struct
  2. 28a5e35 - Bmap file integrity check
  3. 0ad8bb8 - Remote Bmap file integrity check
  4. 12a113f - Add comprehensive test cases and fix deprecation warning

All tests pass, no warnings. The commits are ready locally but need a force push to update the remote branch.

Copilot AI changed the title Rebase bmap file integrity check onto main and add test coverage Cherry-pick bmap file integrity check onto main and add test coverage Nov 1, 2025
Copilot finished work on behalf of sjoerdsimons November 1, 2025 15:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants