Skip to content

[Bug] Windows: Projects Remote file tree empty — git-credential-nostr path mangled by MinGW bash #3025

Description

@bcrdejong

Describe the bug
On Windows, the Projects Remote file view is empty and Sync/Clone fails. Authentication never succeeds because the absolute git-credential-nostr path Buzz injects into credential.helper uses backslashes, which Git for Windows' MinGW bash treats as escape sequences and strips.

Example error:

Could not fetch repository.
Cloning into 'C:\Users\<user>\AppData\Local\Temp\tmpXXXXX\repo'...
C:\Users\<user>\AppData\Local\Buzz\git-credential-nostr.exe get: line 1:
C:Users<user>AppDataLocalBuzzgit-credential-nostr.exe: command not found
fatal: could not read Username for 'https://<relay>/git/<pubkey>/<repo>':
terminal prompts disabled

The same relay/repo works on macOS without extra configuration.

Root cause (short)
Buzz sets credential.helper from Path::display(), which on Windows yields C:\...\git-credential-nostr.exe. Git for Windows invokes helpers via sh.exe; bash mangles the path → helper not found → NIP-98 auth fails → Remote blobless clone fails → empty tree.

Projects git also sets GIT_CONFIG_GLOBAL=/dev/null, so user ~/.gitconfig workarounds do not apply.

This is not a missing/stub helper binary — the shipped git-credential-nostr.exe is functional once the path is passed with forward slashes.

Steps to reproduce

  1. Install Buzz on Windows (Git for Windows required)
  2. Connect to a Buzz relay that has a repository with at least one pushed branch
  3. Open Projects → select the repository → switch to Remote
  4. Observe an empty file tree
  5. Press Sync / Clone and observe the mangled-path / command not found error above

Expected behavior
Remote view shows the repository file tree, and Sync/Clone authenticates via git-credential-nostr the same as on macOS.

Version and platform

  • Buzz version: local build from fix branch / 0.4.26 NSIS (also reproduces on prior Windows installers)
  • OS: Windows 11
  • Git: Git for Windows 2.55.x

Logs / additional context
Reproduced by simulating Buzz's GIT_CONFIG_* injection:

  • Backslash helper path → exact command not found mangling
  • Forward-slash helper path (C:/Users/.../git-credential-nostr.exe) → helper runs successfully

Fix PR
#3023

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions