fix: create logs dir before writing llm request log#8522
Merged
jh-block merged 1 commit intoaaif-goose:mainfrom Apr 16, 2026
Merged
fix: create logs dir before writing llm request log#8522jh-block merged 1 commit intoaaif-goose:mainfrom
jh-block merged 1 commit intoaaif-goose:mainfrom
Conversation
RequestLog::start opened <state>/logs/llm_request.<uuid>.jsonl with File::create, which creates the file but not its parent directory. On fresh installs (or when the logs dir was cleared), every provider streaming request failed with ENOENT, and the test_stream_ollama_timeout_on_stall test panicked. Call fs_err::create_dir_all on the logs dir at the top of RequestLog::start so callers no longer need to pre-create it. Signed-off-by: Juan Palomino <jpalomino09@gmail.com>
jh-block
approved these changes
Apr 16, 2026
jh-block
added a commit
to sunilkumarvalmiki/goose
that referenced
this pull request
Apr 16, 2026
…l-placeholder * origin/main: (64 commits) fix: expand tool calls by default when Response Style is Detailed (aaif-goose#8478) fix: create logs dir before writing llm request log (aaif-goose#8522) fix: enable token usage tracking and configurable stream timeout for Ollama provider (aaif-goose#8493) fix tauri-plugin-dialog version constraint to match other plugins (aaif-goose#8542) call goose serve from tauri frontend via goose-acp client (aaif-goose#8549) failed the script when bundle:default fails and cleanup "alpha" (aaif-goose#8580) pass globally unique conversation identifier as sessionId in databricks api call (aaif-goose#8576) fix: use sqlx chrono decode for thread timestamps instead of manual parsing (aaif-goose#8575) docs: remove stale gemini-acp references (aaif-goose#8572) show individual untracked files in git changes widget (aaif-goose#8574) fix: update publishing flow to include new sdk dir (aaif-goose#8573) fix: remove double border on content in chat (aaif-goose#8545) chore(goose2): `just goose2 <command>` with the addition of `just goose2 kill` (aaif-goose#8570) Lifei/oltp data (aaif-goose#8458) Sidebar polish: search copy, dividers, project reorder, fix DnD (aaif-goose#8568) remove the workflow_dispatch check (aaif-goose#8563) fix: one more rename (aaif-goose#8562) fix(desktop): accept self-signed certs from configured external goosed host (aaif-goose#8400) alexhancock/npm-bumps (aaif-goose#8557) Remove npm publish from release for now (aaif-goose#8558) ...
michaelneale
added a commit
that referenced
this pull request
Apr 17, 2026
* main: (37 commits) polish: refine sidebar activity indicators, add placeholder token, and tidy search field (#8606) feat: add /edit command to cli for on-demand prompt editing (#8566) docs(mcp): add Rendex MCP Server extension tutorial (#8541) Lifei/delete tauri backend acp (#8582) chore: set goose binaries as executable in package.json (#8589) feat: add Novita AI as declarative provider (#8432) feat: add Kimi Code provider with OAuth device flow authentication (#8466) fix: chat loading-state model placeholder (#8431) fix: expand tool calls by default when Response Style is Detailed (#8478) fix: create logs dir before writing llm request log (#8522) fix: enable token usage tracking and configurable stream timeout for Ollama provider (#8493) fix tauri-plugin-dialog version constraint to match other plugins (#8542) call goose serve from tauri frontend via goose-acp client (#8549) failed the script when bundle:default fails and cleanup "alpha" (#8580) pass globally unique conversation identifier as sessionId in databricks api call (#8576) fix: use sqlx chrono decode for thread timestamps instead of manual parsing (#8575) docs: remove stale gemini-acp references (#8572) show individual untracked files in git changes widget (#8574) fix: update publishing flow to include new sdk dir (#8573) fix: remove double border on content in chat (#8545) ...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
RequestLog::startopened<state>/logs/llm_request.<uuid>.jsonlwithFile::create, which creates the file but not its parent directory. On fresh installs (or when thelogs/directory was cleared), every provider streaming request failed withENOENT, and theproviders::ollama::tests::test_stream_ollama_timeout_on_stalltest panicked at theRequestLog::start(...).unwrap()call.This change calls
fs_err::create_dir_allon the logs directory at the top ofRequestLog::startso the rename infinish()and the file write here both have a guaranteed parent. The existing workaround incrates/goose-acp/tests/fixtures/mod.rs(which pre-creates the dir before tests run) is no longer load-bearing.Testing
providers::utils::tests::test_request_log_start_creates_logs_dir— pointsGOOSE_PATH_ROOTat a fresh tempdir, assertslogs/does not exist, callsRequestLog::start, asserts it now exists. Uses the sameenv_lockpattern asproviders::init::tests.cargo test -p goose --lib providers::utils::tests::test_request_log_start_creates_logs_dir -- --exact— passes.cargo fmt --check -p goose— clean.cargo clippy -p goose --lib --tests -- -D warnings— clean.Related Issues
Fixes #8485