Skip to content

[Bug] fetchUserRepositories() silently swallows errors #562

@PhilixTheExplorer

Description

@PhilixTheExplorer

Bug Description

fetchUserRepositories() in scrumHelper.js has empty catch blocks that silently swallow errors (lines 2285-2286):
Both outer and inner catch blocks are completely empty:

} catch (err) {}  // Line 2285 GraphQL fetch error
} catch (err) {}  // Line 2286 outer function error

When the GraphQL request fails or any network error occurs, the function returns undefined instead of []. Callers like performRepoFetch() in popup.js (line 1439) then set availableRepos = undefined, causing availableRepos.filter(...) to crash with a TypeError.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Disconnect network or use an invalid GitHub token
  2. Enable repository filtering and trigger a repo fetch
  3. Observe: no error message shown, repo filter UI crashes silently

Expected Behavior

  • Errors should be logged to console with meaningful messages
  • Function should return [] on failure so callers don't crash

Actual Behavior

  • No error message shown, repo filter UI crashes silently

Screenshots

N/A

Additional Context

Add any other context about the problem here.


Contribution Checklist

  • I have searched existing issues to ensure this bug hasn't been reported
  • I have provided clear reproduction steps
  • I have included relevant environment details
  • I have described both expected and actual behavior

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions