Skip to content

fix(agent): resolve oauth cache home cross-platform - #5151

Open
kalvinnchau wants to merge 1 commit into
block:mainfrom
kalvinnchau:windows-xp/fix-windows-oauth-home
Open

fix(agent): resolve oauth cache home cross-platform#5151
kalvinnchau wants to merge 1 commit into
block:mainfrom
kalvinnchau:windows-xp/fix-windows-oauth-home

Conversation

@kalvinnchau

Copy link
Copy Markdown
Contributor

Summary

  • resolve the OAuth cache home directory with the repository's platform-aware dirs convention
  • preserve the existing .config/buzz-agent/oauth cache layout on macOS and Linux
  • make the cache-path regression assertion portable across path separators

Problem

buzz-agent read only $HOME when constructing the OAuth token cache path. Packaged Windows processes do not guarantee that Unix variable, so OAuth source construction failed with oauth cache: $HOME not set even though Windows had a valid user profile.

Validation

Independent reviewers validated exact commit 836d820483b141b7291170cb33535ac7cb49b2eb on Windows/MSVC with HOME unset and USERPROFILE present:

  • cargo +1.94.1 clippy -p buzz-agent --all-targets --locked -- -D warnings
  • cargo +1.94.1 fmt --all -- --check
  • git diff --check f53bbd1..836d820
  • auth:: tests: 11/11 passed with HOME unset
  • full package lib target: 396 passed / 2 failed; identical-base controls classified both as pre-existing Windows failures

The changed regression fails on the base with $HOME not set and passes on this branch. dirs 6.0.0 was already locked by other workspace crates; the lockfile change adds only the buzz-agent dependency edge.

@kalvinnchau
kalvinnchau requested a review from a team as a code owner August 7, 2026 04:42
Co-authored-by: Kalvin C <kalvinnchau@users.noreply.github.com>
Signed-off-by: Kalvin C <kalvinnchau@users.noreply.github.com>
@kalvinnchau
kalvinnchau force-pushed the windows-xp/fix-windows-oauth-home branch from 836d820 to b3b1528 Compare August 7, 2026 05:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant