pub enum DescriptorCacheError {
Show 69 variants
RelativeCacheDirectory(PathBuf),
RelativeManagedDirectory {
kind: &'static str,
path: PathBuf,
},
NormalizeManagedDirectory {
path: PathBuf,
source: Error,
},
OverlappingManagedDirectories {
first_kind: &'static str,
first: PathBuf,
second_kind: &'static str,
second: PathBuf,
},
UnsafeManagedDirectory {
kind: &'static str,
managed: PathBuf,
working: PathBuf,
},
TargetOutsideSourceExclusion {
target: PathBuf,
exclusion: PathBuf,
},
UnsafeSourceExclusion {
exclusion: PathBuf,
working: PathBuf,
},
GeneratedStateOutsideSourceExclusion {
kind: &'static str,
path: PathBuf,
exclusion: PathBuf,
},
CreateCacheDirectory {
path: PathBuf,
source: Error,
},
UnsafeCacheEntry(PathBuf),
OpenCacheLock {
path: PathBuf,
source: Error,
},
AcquireCacheLock {
path: PathBuf,
source: Error,
},
InvalidDirtyMarker(PathBuf),
DirtyTargetMismatch {
expected: PathBuf,
actual: PathBuf,
},
DirtyStagingMismatch {
expected: PathBuf,
actual: PathBuf,
},
RecoveryDidNotFullyRebuild,
UnownedRecoveryTarget(PathBuf),
UnownedRecoveryStaging(PathBuf),
ReadDescriptorTargetMarker {
path: PathBuf,
source: Error,
},
ReadDescriptorStagingMarker {
path: PathBuf,
source: Error,
},
UnsafeRecoveryDirectory {
kind: &'static str,
path: PathBuf,
},
RemoveRecoveryDirectory {
kind: &'static str,
path: PathBuf,
source: Error,
},
DescriptorCargo(DescriptorCargoRunError),
HashCurrentInput {
path: PathBuf,
source: Error,
},
ConflictingSidecarArtifactEvidence {
path: PathBuf,
first: String,
second: String,
unit: DescriptorCargoUnitId,
extern_name: String,
},
NonUtf8CargoPath(PathBuf),
DuplicateArtifactCoordinate(String),
ArtifactMissingFromCurrentEvidence,
AmbiguousCurrentArtifactEvidence,
MultipleFreshUnitsForArtifact {
coordinate: String,
first: DescriptorCargoUnitId,
second: DescriptorCargoUnitId,
},
MissingArtifactSetSnapshot {
coordinate: String,
},
MissingArtifactIndex {
coordinate: String,
},
RebuiltArtifactMissingFreshUnit {
coordinate: String,
},
InterruptedUnitMissingArtifact(DescriptorCargoUnitId),
ConflictingInterruptedUnitCandidates(DescriptorCargoUnitId),
ParseCacheFile {
path: PathBuf,
source: Error,
},
ReadCacheFile {
path: PathBuf,
source: Error,
},
UnsupportedCacheSchema {
path: PathBuf,
actual: u16,
expected: u16,
},
CachedSidecarSchemaMismatch {
path: PathBuf,
actual: u16,
expected: u16,
},
CachedSidecarUnitMismatch {
unit: DescriptorCargoUnitId,
actual: String,
},
CachedSidecarObjectPathMismatch {
unit: DescriptorCargoUnitId,
actual: String,
expected: String,
},
CacheCoordinateMismatch {
path: PathBuf,
expected: String,
actual: String,
},
SnapshotArtifactSetMismatch(PathBuf),
InvalidCachedUnitId {
path: PathBuf,
source: WrapperError,
},
InvalidCachedGenerationHash {
path: PathBuf,
field: &'static str,
value: String,
reason: String,
},
DuplicateCachedUnit {
path: PathBuf,
unit: DescriptorCargoUnitId,
},
CachedUnitClaimedByMultipleArtifacts {
unit: DescriptorCargoUnitId,
first: String,
second: String,
},
MissingCachedUnitFile {
unit: DescriptorCargoUnitId,
kind: CacheUnitFileKind,
path: PathBuf,
},
MissingMergedUnit(DescriptorCargoUnitId),
ConflictingPrevalidatedObjectHash {
unit: DescriptorCargoUnitId,
first: String,
second: String,
},
ConflictingCachedGeneration {
unit: DescriptorCargoUnitId,
first: String,
second: String,
},
MissingCachedGeneration(DescriptorCargoUnitId),
CachedGenerationObjectHashMismatch {
unit: DescriptorCargoUnitId,
pointer: String,
sidecar: String,
},
CachedSidecarHashMismatch {
unit: DescriptorCargoUnitId,
expected: String,
actual: String,
},
InvalidCachedSidecar {
unit: DescriptorCargoUnitId,
path: PathBuf,
reason: String,
},
CachedOutDirDependencyMismatch {
unit: DescriptorCargoUnitId,
source: WrapperError,
},
CachedDependencyNotEnumerated {
unit: DescriptorCargoUnitId,
extern_name: String,
path: PathBuf,
},
AmbiguousCachedDependencyArtifact {
unit: DescriptorCargoUnitId,
extern_name: String,
path: PathBuf,
matches: usize,
},
StaleCachedDependency {
unit: DescriptorCargoUnitId,
extern_name: String,
path: PathBuf,
expected: String,
actual: String,
},
CachedArtifactJoinMismatch {
unit: DescriptorCargoUnitId,
expected: String,
actual: String,
},
MergedSidecars(DescriptorSidecarError),
ArtifactJoin(UnitArtifactJoinError),
SerializeCacheRecord(Error),
DescriptorObjectHashMismatch {
unit: DescriptorCargoUnitId,
expected: String,
actual: String,
},
CachePathWithoutParent(PathBuf),
InvalidCacheFilename(PathBuf),
ReadCacheSource {
path: PathBuf,
source: Error,
},
WriteCacheFile {
path: PathBuf,
source: Error,
},
ConflictingCacheEntry(PathBuf),
}Expand description
Fail-closed descriptor-cache error.
Variants§
RelativeCacheDirectory(PathBuf)
Cache identity must not depend on the caller’s current directory.
RelativeManagedDirectory
Every managed directory must use an absolute deletion-safe identity.
NormalizeManagedDirectory
Symlinks and lexical aliases are resolved before overlap checks.
OverlappingManagedDirectories
Cache, staging, and descriptor target are exact disjoint roots.
Fields
UnsafeManagedDirectory
Recovery roots may never contain the Cargo working directory.
Fields
TargetOutsideSourceExclusion
The exact descriptor target must be within the phase-invariant generated root.
UnsafeSourceExclusion
Excluding an ancestor of the package would erase actual source inputs.
GeneratedStateOutsideSourceExclusion
In-package cache state must live beneath the one exact excluded subtree.
Fields
CreateCacheDirectory
Persistent cache layout could not be created.
UnsafeCacheEntry(PathBuf)
Cache and lock namespaces must not be redirected by symlinks/special files.
OpenCacheLock
Per-cache generation lock could not be opened.
AcquireCacheLock
Another process owns this cache generation until the OS lock releases.
InvalidDirtyMarker(PathBuf)
The crash marker itself may not be redirected through a symlink.
DirtyTargetMismatch
A dirty cache cannot authorize deletion of another target namespace.
DirtyStagingMismatch
Rebinding a normalized journal path to the request’s lexical source exclusion must preserve its exact filesystem identity.
Fields
RecoveryDidNotFullyRebuild
Recovery requires a Cargo run in the freshly recreated target.
UnownedRecoveryTarget(PathBuf)
Recovery deletion is allowed only for a marker-proven target.
UnownedRecoveryStaging(PathBuf)
Staging deletion requires its own runner-written marker.
ReadDescriptorTargetMarker
Target marker inspection failed.
ReadDescriptorStagingMarker
Staging ownership marker inspection failed.
UnsafeRecoveryDirectory
A recovery path was replaced with a file or symlink.
RemoveRecoveryDirectory
Exact request-owned recovery state could not be removed.
DescriptorCargo(DescriptorCargoRunError)
Descriptor Cargo run failed.
HashCurrentInput
A current Cargo-enumerated input could not be hashed.
ConflictingSidecarArtifactEvidence
Two descriptor rustc invocations observed different bytes at one exact Cargo artifact path.
Fields
unit: DescriptorCargoUnitIdUnit contributing the conflict.
NonUtf8CargoPath(PathBuf)
Cargo paths originate in JSON and must remain exact UTF-8 strings.
DuplicateArtifactCoordinate(String)
Two current artifacts collapsed to one deterministic Cargo coordinate.
ArtifactMissingFromCurrentEvidence
A joined artifact unexpectedly disappeared from current evidence.
AmbiguousCurrentArtifactEvidence
Current Cargo messages contained indistinguishable artifacts.
MultipleFreshUnitsForArtifact
Multiple fresh units cannot own one Cargo artifact.
Fields
first: DescriptorCargoUnitIdFirst fresh unit.
second: DescriptorCargoUnitIdSecond fresh unit.
MissingArtifactSetSnapshot
No-op recovery requires the exact prior complete artifact-set snapshot.
MissingArtifactIndex
A fresh Cargo artifact has no explicit positive or negative cache index.
RebuiltArtifactMissingFreshUnit
A rebuilt artifact emitted no fresh wrapper unit.
InterruptedUnitMissingArtifact(DescriptorCargoUnitId)
Interrupted staging is authoritative only when its unit joins an exact artifact from the recovery Cargo invocation.
ConflictingInterruptedUnitCandidates(DescriptorCargoUnitId)
Two recovery attempts claimed the same unit with different validated sidecar content, so neither is preferred implicitly.
ParseCacheFile
Corrupt cache JSON.
ReadCacheFile
Cache file read failed.
UnsupportedCacheSchema
Cache schema mismatch.
CachedSidecarSchemaMismatch
A cached wrapper sidecar uses another wrapper schema.
CachedSidecarUnitMismatch
Cache filename/unit selection and sidecar identity diverged.
CachedSidecarObjectPathMismatch
A cached sidecar points outside its exact content-addressed object slot.
Fields
unit: DescriptorCargoUnitIdCache-selected unit.
CacheCoordinateMismatch
Coordinate-addressed filename and record diverged.
Fields
SnapshotArtifactSetMismatch(PathBuf)
Exact snapshot lists another artifact set.
InvalidCachedUnitId
Unit ID text in cache is malformed.
InvalidCachedGenerationHash
Generation pointers contain only exact lowercase content hashes.
Fields
DuplicateCachedUnit
Cache record repeats a unit.
CachedUnitClaimedByMultipleArtifacts
One unit cannot be authorized by two current artifacts.
Fields
unit: DescriptorCargoUnitIdUnit.
MissingCachedUnitFile
Explicitly indexed cache bytes are gone.
MissingMergedUnit(DescriptorCargoUnitId)
Fresh and cached staging did not contain an authorized unit.
ConflictingPrevalidatedObjectHash
One materialized unit cannot have two verified object hashes.
Fields
unit: DescriptorCargoUnitIdMaterialized unit.
ConflictingCachedGeneration
One logical Cargo unit cannot select two cache generations at once.
Fields
unit: DescriptorCargoUnitIdLogical unit.
MissingCachedGeneration(DescriptorCargoUnitId)
Every merged sidecar must have a committed immutable generation.
CachedGenerationObjectHashMismatch
Pointer and sidecar must agree on the immutable object blob.
Fields
unit: DescriptorCargoUnitIdLogical unit.
CachedSidecarHashMismatch
Immutable sidecar bytes must match their generation address.
Fields
unit: DescriptorCargoUnitIdLogical unit.
InvalidCachedSidecar
A content-addressed sidecar failed the wrapper protocol’s semantic validation before its cache object was admitted to the linker.
Fields
unit: DescriptorCargoUnitIdLogical unit.
CachedOutDirDependencyMismatch
A cached unit’s rustc-declared generated-source inputs changed or are no longer safe beneath the persistent descriptor target.
Fields
unit: DescriptorCargoUnitIdCached unit.
source: WrapperErrorExact generated-input validation failure.
CachedDependencyNotEnumerated
Cached unit points at a dependency absent from current Cargo artifacts.
Fields
unit: DescriptorCargoUnitIdCached unit.
AmbiguousCachedDependencyArtifact
One exact dependency path must belong to one Cargo artifact message.
Fields
unit: DescriptorCargoUnitIdCached unit.
StaleCachedDependency
Cached dependency bytes changed after the wrapper observed them.
Fields
unit: DescriptorCargoUnitIdUnit.
CachedArtifactJoinMismatch
Artifact-specific index did not join back to that exact current artifact.
Fields
unit: DescriptorCargoUnitIdUnit.
MergedSidecars(DescriptorSidecarError)
Merged sidecars/objects failed existing strict validation.
ArtifactJoin(UnitArtifactJoinError)
Sidecar/Cargo join failed.
SerializeCacheRecord(Error)
Cache record serialization failed.
DescriptorObjectHashMismatch
Cached object’s exact bytes disagree with its sidecar.
CachePathWithoutParent(PathBuf)
Cache path has no parent.
InvalidCacheFilename(PathBuf)
Cache filename cannot support an atomic temporary sibling.
ReadCacheSource
Source bytes for an atomic cache copy could not be read.
WriteCacheFile
Atomic cache write failed.
ConflictingCacheEntry(PathBuf)
Immutable content address already contains different bytes.
Trait Implementations§
Source§impl Debug for DescriptorCacheError
impl Debug for DescriptorCacheError
Source§impl Display for DescriptorCacheError
impl Display for DescriptorCacheError
Source§impl Error for DescriptorCacheError
impl Error for DescriptorCacheError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()
Auto Trait Implementations§
impl !RefUnwindSafe for DescriptorCacheError
impl !UnwindSafe for DescriptorCacheError
impl Freeze for DescriptorCacheError
impl Send for DescriptorCacheError
impl Sync for DescriptorCacheError
impl Unpin for DescriptorCacheError
impl UnsafeUnpin for DescriptorCacheError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more