You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Protect crate metadata from corruption via SHA-256 hash
We now compute a SHA-256 of the raw (encoded) crate metadata,
and append it to the final crate metadata that we store on disk.
When we load the metadata, we compute the hash from the metadata
blob, and verify that matches the hash stored at the end of the
blob.
This allows us to detect on-disk corruption of the metadata file,
which might later cause a build failure much later in compilation.
If anyone is manually editing crate metadata on-disk,
they will need to re-compute and modify the hash at
the end of the blob.
This will allow us to determine whether or not crate metadata
corruption is causing some of the unusual incr-comp failures
we've been seeing. The incremental compilation data itself
will be hashed in a follow-up PR.
0 commit comments