MoonshotAI / MoonshotAI/kimi-code
fix(web): dev:stub command fails because dev/stub-daemon.mjs is missing
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 7.5k
- Forks
- 1.2k
- Avg merge
- 11h 53m
- Merged PRs (30d)
- 350
Description
Bug description
The dev:stub script in apps/kimi-web/package.json points to dev/stub-daemon.mjs, but that file does not exist on the main branch. Running the command fails with MODULE_NOT_FOUND.
Reproduction steps
- Clone the repo and checkout
main - Run:
pnpm -C apps/kimi-web run dev:stub - Observe the error:
Error: Cannot find module '/.../kimi-code/apps/kimi-web/dev/stub-daemon.mjs' code: 'MODULE_NOT_FOUND'
Expected behavior
The dev:stub command should start a local stub daemon for offline development, as documented in apps/kimi-web/README.md.
Actual behavior
The command crashes immediately because apps/kimi-web/dev/ directory and stub-daemon.mjs are missing.
Environment
- Branch:
main - Node.js: 24.15.0
- pnpm: 10.33.0
Additional context
- The file is not tracked in
origin/main(git ls-tree -r --name-only origin/main | grep stub-daemonreturns nothing). - The directory
apps/kimi-web/dev/does not exist. - The file is not ignored by
.gitignore. - The file does exist in repository history on other branches (
git log --all -- apps/kimi-web/dev/stub-daemon.mjsshows commits), but it never made it tomainor was removed at some point. README.mdstill documents this command in the "Offline / no server" section.
I’m happy to help restore or rewrite the stub daemon if the team confirms the intended behavior.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Inspect the dev:stub script in apps/kimi-web/package.json and the Offline / no server section of apps/kimi-web/README.md, then review repository history for apps/kimi-web/dev/stub-daemon.mjs. Run pnpm -C apps/kimi-web run dev:stub to confirm the current failure; done means the documented command starts the local stub daemon without MODULE_NOT_FOUND.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, node.js
- Domain
- devtools, web-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100