Skip to content

BUG: Keyring operations silently ignore errors #616

@andrinoff

Description

@andrinoff

Describe the bug

In config/config.go lines 357-360 and 365-366, keyring operations suppress errors with _:

_ = keyring.Set(keyringServiceName, acc.Email, acc.Password)
_ = keyring.Delete(keyringServiceName, acc.Email)

If keyring unavailable or fails, passwords silently fail to persist with no warning/fallback.

To reproduce

  1. Run matcha on system without keyring support
  2. Save password - keyring.Set fails silently
  3. Restart matcha - password lost, no indication why
  4. User confused about missing credentials

Expected behavior

Log keyring errors as warnings:

if err := keyring.Set(keyringServiceName, acc.Email, acc.Password); err != nil {
    log.Printf("Warning: failed to store password in keyring: %v", err)
}

Or provide fallback mechanism for systems without keyring.

Screenshots

N/A

Additional context

  • File: config/config.go
  • Lines: 357-360, 365-366
  • Severity: Medium - silent credential loss
  • Fix complexity: Easy - add logging/warning

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions