MoonshotAI / MoonshotAI/kimi-cli

Edit/Write tools report success but never write to disk (0.38.0, macOS)

Open
#2,617 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
11.4k
Forks
1.3k
Avg merge
9h 47m
Merged PRs (30d)
2

Description

Summary

Since 2026-08-25 ~17:00 UTC, both the Edit and Write tools silently no-op in my sessions: they return success ("The file has been updated..." / "File created successfully") but nothing is ever written to disk. 100% reproducible.

Environment

  • Kimi Code CLI 0.38.0 (~/.kimi-code/bin/kimi)
  • macOS (Apple Silicon), /bin/bash
  • Regular user home directory, no sandbox

Repro (Edit)

  1. Bash tool: printf 'alpha\n' > /tmp/t.txt
  2. Read tool on /tmp/t.txt → shows alpha
  3. Edit tool: old_string alpha → new_string omega → returns "The file has been updated"
  4. Bash: cat /tmp/t.txt → still alpha; ls -la shows mtime unchanged; Read tool also still shows alpha.

Repro (Write)

  1. Write tool to a non-existent path → returns "File created successfully"
  2. File does not exist afterwards (cat: No such file or directory).

What still works

  • Read tool (shows true disk content)
  • Bash tool file writes (heredoc, printf)
  • Earlier the same day (before a context compaction in the same session), Write genuinely worked — a 13 KB markdown file was created and re-verified from disk.

Scope / persistence

  • Affects paths inside and outside the working directory; plain UTF-8 LF text files.
  • Persists across kimi session restarts and a full macOS reboot (session resumed).
  • Nothing relevant in ~/.kimi-code/logs/kimi-code.log at INFO level around the tool calls.
  • Possibly related scheduler issue observed in the same period: a deleted cron job kept firing 4 more times after deletion (CronList empty, CronDelete reported "no cron job with id"). This stopped after a CLI restart.

Impact

Any agentic edit workflow silently loses work: the model believes edits landed and proceeds on false state. In my case 7 "successful" edits across 4 files were lost before disk verification caught it.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure with the Edit and Write tools, then verify results using Read, Bash, and direct disk checks. Inspect the tool execution path and ~/.kimi-code/logs/kimi-code.log around the calls, comparing it with the working Bash writes. Done means both tools persist changes and newly created files across session restarts.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
cli
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.