Skip to content

fix(kimi-code): render newlines instead of literal backslash-n in rc output - #3244

Merged
sailist merged 2 commits into
MoonshotAI:mainfrom
sailist:feat-000-08-06-rc
Aug 25, 2026
Merged

fix(kimi-code): render newlines instead of literal backslash-n in rc output#3244
sailist merged 2 commits into
MoonshotAI:mainfrom
sailist:feat-000-08-06-rc

Conversation

@sailist

@sailist sailist commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator

Related Issue

Follow-up fix to #3034 (merged). The bug ships only with that unreleased feature, so no separate issue.

Problem

kimi rc (kimi web --remote-control) printed literal \n characters instead of line breaks in its terminal output — the entire banner, status lines, and QR footer rendered as one wrapped blob of text.

What changed

In apps/kimi-code/src/cli/sub/web/remote-control.ts, five places used a double-escaped '\\n' (literal backslash + n) instead of a real newline:

  • formatRemoteControlOutput joined its lines with .join('\\n').
  • formatRemoteControlStatus ended all four status templates with \\n.

Both now use '\n', so the output renders with actual line breaks. No behavior change beyond the visible formatting fix.

Verified with the existing CLI/TUI web test suites (test/cli/web/web.test.ts, test/tui/commands/web.test.ts, 76 tests) and a rebuilt SEA binary.

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked a related issue (external PRs: the issue must have a maintainer's /approve).
  • I have added tests that prove my feature works.
  • Ran gen-changesets skill, or this PR needs no changeset. (No changeset: the bug is part of the unreleased Remote Control feature whose changeset add-remote-control.md is still pending release.)
  • Ran gen-docs skill, or this PR needs no doc update.

@changeset-bot

changeset-bot Bot commented Aug 25, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 60579b0

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

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

@pkg-pr-new

pkg-pr-new Bot commented Aug 25, 2026

Copy link
Copy Markdown
pnpm dlx https://pkg.pr.new/@moonshot-ai/kimi-code@60579b0
npx https://pkg.pr.new/@moonshot-ai/kimi-code@60579b0

commit: 60579b0

@sailist
sailist force-pushed the feat-000-08-06-rc branch from 1194e2d to 1b2218f Compare August 25, 2026 13:09
@sailist
sailist force-pushed the feat-000-08-06-rc branch from 1b2218f to 60579b0 Compare August 25, 2026 13:19
@sailist
sailist merged commit de0f6b1 into MoonshotAI:main Aug 25, 2026
15 checks passed
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.

1 participant