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

feat: store patch hash on disk #169

Merged
merged 1 commit into from
May 21, 2024
Merged

feat: store patch hash on disk #169

merged 1 commit into from
May 21, 2024

Conversation

bryanoltman
Copy link
Contributor

Description

Write patch hash to disk alongside number and size.

Type of Change

  • ✨ New feature (non-breaking change which adds functionality)
  • 🛠️ Bug fix (non-breaking change which fixes an issue)
  • ❌ Breaking change (fix or feature that would cause existing functionality to change)
  • 🧹 Code refactor
  • ✅ Build configuration change
  • 📝 Documentation
  • 🗑️ Chore

@@ -17,13 +17,17 @@ const PATCHES_DIR_NAME: &str = "patches";
const PATCHES_STATE_FILE_NAME: &str = "patches_state.json";
const PATCH_ARTIFACT_FILENAME: &str = "dlc.vmcode";

#[derive(Copy, Clone, Debug, Deserialize, Serialize, PartialEq, Eq, Hash)]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

String does not implement Copy, so we lose the ability to make this struct Copyable. This is why this PR introduces the as_refs and clones below.

Copy link
Contributor

Choose a reason for hiding this comment

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

This will I guess all go away when we store the hash inside the artifact (bundle) in some way I guess.

Copy link

codecov bot commented May 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.21%. Comparing base (a2e9f5d) to head (821d79b).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #169      +/-   ##
==========================================
+ Coverage   96.19%   96.21%   +0.02%     
==========================================
  Files          28       28              
  Lines        3126     3148      +22     
==========================================
+ Hits         3007     3029      +22     
  Misses        119      119              
Flag Coverage Δ
library 97.87% <100.00%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@bryanoltman bryanoltman merged commit 5de07bb into main May 21, 2024
8 checks passed
@bryanoltman bryanoltman deleted the bo/store-patch-hash branch May 21, 2024 18:38
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.

3 participants