Fix nix references in prose that no longer resolve
Nine of the 38 .nix tokens mentioned anywhere in *.rs did not name anything that exists. Twelve mentions, five distinct targets: hive-c0re.nix, hive-gateway.nix and hive-forge.nix are all directories now; nix/modules/ is not a directory we have; hive-forge-tools.nix was a bash script the binary replaced and is gone. Where the reference is load-bearing it is corrected rather than deleted, because the reference is the point: a comment saying a constant must match a nix literal is only useful if you can open the file it names. Where the module member was unambiguous the path now names it exactly. paths.rs's STATE_ROOT marker was the worst of them: it claimed the value came from services.hyperhive.c0re.statePath, in hive-c0re.nix. Neither exists. The option is not declared anywhere and the file is a directory, so a "must match" contract pointed at two things that cannot be opened. /var/lib/hyperhive is hardcoded on both sides, which is what the comment now says. hive-forge-tools.nix keeps no replacement: naming a file that was deliberately deleted helps nobody, and "replaces a prior bash script" is complete without it. Measured before and after with the same command: 9 unresolved of 38 before, 4 of 35 after. The remaining four are an example path in a doc comment, an upstream nixpkgs path, and two from one synthetic test fixture.
This commit is contained in:
parent
5593fa76bb
commit
06e8a9a09e
9 changed files with 17 additions and 13 deletions
|
|
@ -160,7 +160,7 @@ async fn dispatch(req: &HostRequest, coord: Arc<Coordinator>) -> HostResponse {
|
|||
HostRequest::AgentExists { name } => HostResponse::agent_exists(agent_exists(name)?),
|
||||
HostRequest::AgentStatus => handle_agent_status(&coord).await,
|
||||
// The hive domain + per-surface public URLs are injected into
|
||||
// c0re's service env by hive-c0re.nix; surface them so the
|
||||
// c0re's service env by the hyperhive module; surface them so the
|
||||
// operator CLI can fill in this hive's own identity (the
|
||||
// federation peer-config block) and open the web surfaces
|
||||
// (`hivectl open`).
|
||||
|
|
@ -1038,7 +1038,7 @@ fn is_broad_scope(scope: &LifecycleScope) -> bool {
|
|||
}
|
||||
|
||||
/// Assemble this hive's domain + browser-facing web URLs from c0re's
|
||||
/// service env (injected by hive-c0re.nix). Each field is `None` when its
|
||||
/// service env (injected by the hyperhive NixOS module). Each field is `None` when its
|
||||
/// surface isn't browser-reachable (domain unset, forge not behind the
|
||||
/// gateway, matrix GUI off), so the CLI can hint precisely instead of
|
||||
/// opening a dead link. Scheme matches the existing `HIVE_FORGE_PUBLIC_URL`
|
||||
|
|
|
|||
Loading…
Reference in a new issue