hive-c0re: pass build_logs the parent dir, not the broker.sqlite file

Every other Coordinator opener takes the broker.sqlite path and
derives its parent internally; BuildLogs alone wants a directory.
Passing the file path tripped create_dir_all on an existing file
(File exists os error 17) and blocked c0re boot.
This commit is contained in:
müde 2026-05-31 20:53:35 +02:00
commit 7cc2690717
2 changed files with 10 additions and 5 deletions

View file

@ -220,8 +220,13 @@ impl Coordinator {
let questions = OperatorQuestions::open(db_path).context("open operator_questions")?;
let scheduled_prompts = crate::scheduled_prompts::ScheduledPrompts::open(db_path)
.context("open scheduled_prompts")?;
// BuildLogs wants a directory (it picks its own `build_logs.sqlite`
// file under it); every other opener here takes the sibling
// sqlite-file path itself. Derive the dir from `db_path`'s
// parent so the two shapes line up.
let build_logs_dir = db_path.parent().unwrap_or_else(|| Path::new("."));
let build_logs = Arc::new(
crate::build_logs::BuildLogs::open(db_path).context("open build_logs")?,
crate::build_logs::BuildLogs::open(build_logs_dir).context("open build_logs")?,
);
// Install the process-wide handle so `lifecycle::run` /
// `lifecycle::prebuild_toplevel` can write without us having