pub fn env_hash(project_root: &Path, plugin_dirs: &[PathBuf]) -> u64Expand description
Compute environment hash from config + plugins + cha binary fingerprint.
The binary fingerprint covers both cases that make cached SourceModels stale:
- developer rebuilds cha after editing parser code,
- end user upgrades to a new cha release.
Both produce a different on-disk binary, so the binary’s modification
time is sufficient. CARGO_PKG_VERSION was the old key, but it was
a strict subset of this: every release-version bump necessarily writes
a new binary (new mtime), and no parser change ever happens without a
rebuild (new mtime). Version-only tracking missed parser-behaviour
changes that shipped without a cargo xtask bump — this is what let
the header-declaration parser fix silently fail against stale caches.