Skip to content

gitmastery progress sync on should report errors appropriately #154

Description

@jovnc

Context / Background

Reference forum thread: NUS-CS2103-AY2627-S1/forum#22

When executing gitmastery progress sync on, underlying errors encountered during execution (such as GitHub CLI authentication issues, missing permissions, or network/git push failures) are currently swallowed silently or not adequately reported to the user. This leaves users unaware of sync failures or makes debugging difficult.

Expected Behavior

  • Error Visibility: Any errors encountered during the sync enablement process should be captured and surfaced clearly to the user via standard error/output.
  • Actionable Guidance: Provide clear diagnostic feedback indicating the root cause (e.g., missing GitHub authentication, insufficient token scope, or network/remote errors) and suggested steps to resolve it.
  • Exit Status: Ensure the CLI exits with an appropriate non-zero exit code when the operation fails.

Steps to Reproduce

  1. Trigger an error condition (e.g., logged out of gh, revoked scopes, or disconnected network).
  2. Run gitmastery progress sync on.
  3. Observe that errors are suppressed rather than surfaced with clear diagnostic messages and proper exit codes.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions