core: fix idle CPU use in file logger (#31478)
This commit is contained in:
parent
5372c63c7c
commit
2ababc87da
1 changed files with 1 additions and 1 deletions
|
|
@ -47,7 +47,7 @@ function format(input: unknown) {
|
||||||
}
|
}
|
||||||
|
|
||||||
export function fileLogger(file = path.join(Global.Path.log, "opencode.log"), id: string = runID) {
|
export function fileLogger(file = path.join(Global.Path.log, "opencode.log"), id: string = runID) {
|
||||||
return Logger.toFile(formatter(id), file, { flag: "a", batchWindow: 0 })
|
return Logger.toFile(formatter(id), file, { flag: "a" })
|
||||||
}
|
}
|
||||||
|
|
||||||
const stderrLogger = Logger.make((options) => process.stderr.write(formatter().log(options) + "\n"))
|
const stderrLogger = Logger.make((options) => process.stderr.write(formatter().log(options) + "\n"))
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue