Environment
I'm using moonup.
$ uname -a
Linux asahi 6.14.8-400.asahi.fc42.aarch64+16k #1 SMP PREEMPT_DYNAMIC Fri May 30 20:27:54 UTC 2025 aarch64 GNU/Linux
$ type -p moon
moon is /home/kenoss/.moon/bin/moon
$ moon --version
moon 0.1.20260529 (3e1c753 2026-05-29) ~/.moonup/toolchains/0.9.3+08f337e2c/bin/moon
moonc v0.9.3+08f337e2c (2026-05-29) ~/.moonup/toolchains/0.9.3+08f337e2c/bin/moonc
moonrun 0.1.20260529 (3e1c753 2026-05-29) ~/.moonup/toolchains/0.9.3+08f337e2c/bin/moonrun
Issue
moon build --watch reports success messages by stderr in my environment.
$ moon build --target js --watch --output-json --release > >(sed 's/^/stdout: /') 2> >(sed 's/^/stderr: /' >&2)
stderr: Finished. moon: no work to do
stdout: Success, waiting for filesystem changes...
// edit
stderr: Finished. moon: ran 2 tasks, now up to date
stdout: Success, waiting for filesystem changes...
This leads two issues.
- This plugin shows
MoonBit Build Errors on success
$ npx vite dev
...
--- MoonBit Build Errors ---
Finished. moon: no work to do
https://github.com/mizchi/vite-plugin-moonbit/blob/vite-plugin-moonbit-v0.3.0/src/index.ts#L934
Not critical, but confusing.
- This plugin doesn't reload even if a file is modified.
Because triggerHMR() and handling of "Finished" is called only from a callback for stdout.
Critical.
Q. Is this issue only for my environment?
Note that moonup looks not to be a cause. (~/.moon/bin/moon is moonup-shim, but ~/.moonup/toolchains/0.9.3+08f337e2c/bin/moon is original moon binary. The issue still happens even if I run it directly.)
$ ~/.moonup/toolchains/0.9.3+08f337e2c/bin/moon build --target js --watch --output-json --release > >(sed 's/^/stdout: /') 2> >(sed 's/^/stderr: /' >&2)
stderr: Finished. moon: no work to do
stdout: Success, waiting for filesystem changes...
Environment
I'm using moonup.
Issue
moon build --watchreports success messages by stderr in my environment.This leads two issues.
MoonBit Build Errorson successhttps://github.com/mizchi/vite-plugin-moonbit/blob/vite-plugin-moonbit-v0.3.0/src/index.ts#L934
Not critical, but confusing.
Because triggerHMR() and handling of "Finished" is called only from a callback for stdout.
Critical.
Q. Is this issue only for my environment?
Note that
moonuplooks not to be a cause. (~/.moon/bin/moonismoonup-shim, but~/.moonup/toolchains/0.9.3+08f337e2c/bin/moonis original moon binary. The issue still happens even if I run it directly.)