Skip to content

fix(kimi-code): guard footer PR lookup spawn failures#89

Open
caigee-cmd wants to merge 1 commit into
MoonshotAI:mainfrom
caigee-cmd:codex/fix-issue-87-footer-pr-lookup
Open

fix(kimi-code): guard footer PR lookup spawn failures#89
caigee-cmd wants to merge 1 commit into
MoonshotAI:mainfrom
caigee-cmd:codex/fix-issue-87-footer-pr-lookup

Conversation

@caigee-cmd
Copy link
Copy Markdown

Related Issue

Fixes #87

Problem

A fresh install could crash on startup before the TUI finished rendering. The footer does a best-effort gh pr view lookup, and in the reported environment that spawn path failed with ENOTDIR. Because the failure was thrown synchronously, it escaped the normal callback error handling and took down the process.

What changed

Wrapped the gh pr view spawn in readPullRequest() with a local try/catch so spawn-time failures degrade to null instead of crashing the app.

Also added a regression test that mocks a synchronous spawn ENOTDIR throw and verifies the footer git status still renders normally.

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked a related issue, or explained the problem above.
  • I have added tests that prove my feature works.
  • Ran gen-changesets skill, or this PR needs no changeset.
  • Ran gen-docs skill, or this PR needs no doc update.

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented May 26, 2026

🦋 Changeset detected

Latest commit: 282a87a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@moonshot-ai/kimi-code Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fail to launch Kimi-code

1 participant