LearnNewsExamplesServices
Frontmatter
titlehandles gh absence and ENOENT in HealthService; add unit test
authorMannXo
stateMerged
createdAtNov 7, 2025, 10:35 AM
updatedAtNov 8, 2025, 11:05 AM
closedAtNov 8, 2025, 11:05 AM
mergedAtNov 8, 2025, 11:05 AM
branchesdevenhancement/gh-absent-healthservice
urlhttps://github.com/neomjs/neo/pull/7717
Merged
MannXo
MannXo commented on Nov 7, 2025, 10:35 AM

Summary:

Add explicit ENOENT handling to HealthService so the server reports installed: false when the GitHub CLI (gh) is missing, and add a unit test + runbook. This improves startup clarity and CI coverage so users see a clear, actionable message when gh is not installed or not on PATH.

Does this PR resolve an issue? (Required)

Closes #7713

What kind of change does this PR introduce? (check at least one)

  • Bugfix
  • Feature
  • Code style update
  • Refactor
  • Build-related changes
  • Other, please describe: Enhancement

Does this PR introduce a breaking change? (check one)

  • Yes
  • No

If yes, please describe the impact and migration path for existing applications:

The PR fulfills this requirement:

  • It's submitted to the dev branch, not the main branch

If adding a new feature, the PR's description includes:

  • A convincing reason for adding this feature (to avoid wasting your time, it's best to open a suggestion issue first and wait for approval before working on it)

Other information:

tobiu
tobiu commented on Nov 8, 2025, 11:03 AM

Input from Gemini 2.5 pro:

✦ This PR provides significant and valuable improvements to the GitHub Workflow server's health checks. The enhanced error handling, clearer messaging for gh CLI issues, and the new documentation for gh-absent scenarios are all excellent additions that will greatly improve the developer experience.

We've identified a few areas for further refinement, which we've captured in separate follow-up tickets to keep this PR focused:

  • #7720: Refactor: Inline healthHelpers.mjs into HealthService.mjs
  • #7721: Docs: Create and integrate guide for gh-absent scenarios
  • #7722: Test: Relocate healthHelpers.test.mjs to Playwright harness

These are not blockers for this PR, as the current changes already deliver substantial value. If you're interested in continuing to contribute, we'd be happy for you to tackle any of these follow-up tickets!

Great work on this PR!