diegosouzapw/OmniRoute · error
[HOT_RELOAD] Runtime config reload failed for
Error message
[HOT_RELOAD] Runtime config reload failed for ${source}: What it means
A runtime hot-reload configuration check (triggered by settings change, poll tick, or SQLite file watch) failed while applying runtime settings via applyRuntimeSettings. The error was caught so the watcher/queue loop keeps running, but the config change that triggered it was not applied — the process keeps the previous runtime configuration.
Solutions
- Inspect the logged error to find which setting failed to apply
- Fix or remove the invalid setting value in the settings store
- Trigger another settings change or wait for the next poll tick to re-run the reload
Defensive patterns
Strategy: try-catch
When it happens
Trigger: Thrown at src/lib/config/hotReload.ts:52 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of diegosouzapw/OmniRoute@a179ffed5b (2026-08-25).
Data as JSON: /api/errors/2f9a925ca7b9da91.
Report an issue: GitHub.
Appendix: source
Thrown at src/lib/config/hotReload.ts:52
.join(", ")}`
);
}
async function runHotReloadCheck(source: string) {
const settings = await getSettings();
const changes = await applyRuntimeSettings(settings, { source });
logChanges(source, changes);
}
function queueHotReloadCheck(source: string) {
if (activeCheck) {
queuedSource = source;
return;
}
activeCheck = runHotReloadCheck(source)
.catch((error) => {
console.warn(
`[HOT_RELOAD] Runtime config reload failed for ${source}:`,
error instanceof Error ? error.message : error
);
})
.finally(() => {
activeCheck = null;
if (!queuedSource) return;
const nextSource = queuedSource;
queuedSource = null;
queueHotReloadCheck(nextSource);
});
}
export function startRuntimeConfigHotReload(options: { pollIntervalMs?: number } = {}) {
if (pollTimer || sqliteWatcher) return;
const pollIntervalMs = Math.max(
options.pollIntervalMs || getPollIntervalMs(),View on GitHub (pinned to a179ffed5b)