Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Install MoonBit CLI failed #546

Open
lvyuemeng opened this issue Jul 10, 2024 · 3 comments
Open

Install MoonBit CLI failed #546

lvyuemeng opened this issue Jul 10, 2024 · 3 comments
Assignees

Comments

@lvyuemeng
Copy link

lvyuemeng commented Jul 10, 2024

OS: windows 11
Description:
when I installed moonbit cli, here the output:

failed: moonc build-package -error-format json C:\Users\吕粤蒙.moon\lib\core\builtin\array.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\arraycore.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\arrayview.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\array_block.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\autoloc.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\buffer.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\byte.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\bytes.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\bytes_block.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\console.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\debug.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\fixedarray.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\fixedarray_block.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\int64.wasm.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\intrinsics.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\iter.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\linked_hash_map.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\option.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\result.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\traits.mbt C:\Users\吕粤蒙.moon\lib\core\builtin\unit.mbt -o C:\Users\吕粤蒙.moon\lib\core\target\wasm\release\bundle\builtin\builtin.core -pkg moonbitlang/core/builtin -pkg-sources moonbitlang/core/builtin:C:\Users\吕粤蒙.moon\lib\core\builtin -target wasm
Fatal error: exception Sys_error("C:\Users\\233\141\154\230\155\160\232\143\160\233\146\130\230\169\189.moon\lib\core\builtin\unit.mbt: No such file or directory")
error: failed when bundle
Moonbit installed successfully.

when I upgrade cli with moon upgrade, here the output:

error: failed to copy C:\Users\吕粤蒙.moon\bin\moonc.exe

Caused by:
系统无法将文件移到不同的磁盘驱动器。 (os error 17)

after failed, it will generate a folder like "鍚曠菠钂橽.moon" in user folder.

@lijunchen lijunchen transferred this issue from moonbitlang/moonbit-docs Dec 31, 2024
@dwpeng
Copy link

dwpeng commented Jan 8, 2025

I got same issue while upgrading moon.

➜  ~ moon upgrade
Checking network ...
  Use https://cli.moonbitlang.cn
Checking latest toolchain version ...
Warning: moon upgrade is highly experimental.
If you encounter any problems, please reinstall by visit https://www.moonbitlang.cn/download
Will install to /home/dwp/.moon. Continue? yes

Downloading 100.0%
Compiling moonbitlang/core ...
moon version: moon 0.1.20241219 (e628c26 2024-12-19)

failed: moonc build-package -error-format json /home/dwp/.moon/lib/core/builtin/bytes_block.mbt /home/dwp/.moon/lib/core/builtin/int64_nonjs.mbt /home/dwp/.moon/lib/core/builtin/double_to_int_wasm.mbt /home/dwp/.moon/lib/core/builtin/autoloc.mbt /home/dwp/.moon/lib/core/builtin/tuple_hash.mbt /home/dwp/.moon/lib/core/builtin/uint64.mbt /home/dwp/.moon/lib/core/builtin/iter_upto.mbt /home/dwp/.moon/lib/core/builtin/iter2.mbt /home/dwp/.moon/lib/core/builtin/stringbuilder_buffer.mbt /home/dwp/.moon/lib/core/builtin/bytes.mbt /home/dwp/.moon/lib/core/builtin/iter.mbt /home/dwp/.moon/lib/core/builtin/fixedarray.mbt /home/dwp/.moon/lib/core/builtin/intrinsics.mbt /home/dwp/.moon/lib/core/builtin/bigint_deprecated.mbt /home/dwp/.moon/lib/core/builtin/char.mbt /home/dwp/.moon/lib/core/builtin/hasher.mbt /home/dwp/.moon/lib/core/builtin/result.mbt /home/dwp/.moon/lib/core/builtin/tuple_show.mbt /home/dwp/.moon/lib/core/builtin/traits.mbt /home/dwp/.moon/lib/core/builtin/stringbuilder.mbt /home/dwp/.moon/lib/core/builtin/uninitialized_array.mbt /home/dwp/.moon/lib/core/builtin/option.mbt /home/dwp/.moon/lib/core/builtin/json.mbt /home/dwp/.moon/lib/core/builtin/bytesview.mbt /home/dwp/.moon/lib/core/builtin/tuple_compare.mbt /home/dwp/.moon/lib/core/builtin/assert.mbt /home/dwp/.moon/lib/core/builtin/string.mbt /home/dwp/.moon/lib/core/builtin/bigint_nonjs.mbt /home/dwp/.moon/lib/core/builtin/arraycore_nonjs.mbt /home/dwp/.moon/lib/core/builtin/array_block.mbt /home/dwp/.moon/lib/core/builtin/array.mbt /home/dwp/.moon/lib/core/builtin/linked_hash_set.mbt /home/dwp/.moon/lib/core/builtin/show.mbt /home/dwp/.moon/lib/core/builtin/unit.mbt /home/dwp/.moon/lib/core/builtin/tuple_to_json.mbt /home/dwp/.moon/lib/core/builtin/linked_hash_map.mbt /home/dwp/.moon/lib/core/builtin/tuple_eq.mbt /home/dwp/.moon/lib/core/builtin/failure.mbt /home/dwp/.moon/lib/core/builtin/console.mbt /home/dwp/.moon/lib/core/builtin/fixedarray_block.mbt /home/dwp/.moon/lib/core/builtin/arrayview.mbt /home/dwp/.moon/lib/core/builtin/double_to_int64_wasm.mbt /home/dwp/.moon/lib/core/builtin/byte.mbt -o /home/dwp/.moon/lib/core/target/wasm/release/bundle/builtin/builtin.core -pkg moonbitlang/core/builtin -pkg-sources moonbitlang/core/builtin:/home/dwp/.moon/lib/core/builtin -target wasm
failed: moonc build-package -error-format json /home/dwp/.moon/lib/core/builtin/bytes_block.mbt /home/dwp/.moon/lib/core/builtin/int64_nonjs.mbt /home/dwp/.moon/lib/core/builtin/double_to_int_wasm.mbt /home/dwp/.moon/lib/core/builtin/autoloc.mbt /home/dwp/.moon/lib/core/builtin/tuple_hash.mbt /home/dwp/.moon/lib/core/builtin/uint64.mbt /home/dwp/.moon/lib/core/builtin/iter_upto.mbt /home/dwp/.moon/lib/core/builtin/iter2.mbt /home/dwp/.moon/lib/core/builtin/stringbuilder_buffer.mbt /home/dwp/.moon/lib/core/builtin/bytes.mbt /home/dwp/.moon/lib/core/builtin/iter.mbt /home/dwp/.moon/lib/core/builtin/fixedarray.mbt /home/dwp/.moon/lib/core/builtin/intrinsics.mbt /home/dwp/.moon/lib/core/builtin/bigint_deprecated.mbt /home/dwp/.moon/lib/core/builtin/char.mbt /home/dwp/.moon/lib/core/builtin/hasher.mbt /home/dwp/.moon/lib/core/builtin/result.mbt /home/dwp/.moon/lib/core/builtin/tuple_show.mbt /home/dwp/.moon/lib/core/builtin/traits.mbt /home/dwp/.moon/lib/core/builtin/stringbuilder.mbt /home/dwp/.moon/lib/core/builtin/uninitialized_array.mbt /home/dwp/.moon/lib/core/builtin/option.mbt /home/dwp/.moon/lib/core/builtin/json.mbt /home/dwp/.moon/lib/core/builtin/bytesview.mbt /home/dwp/.moon/lib/core/builtin/tuple_compare.mbt /home/dwp/.moon/lib/core/builtin/assert.mbt /home/dwp/.moon/lib/core/builtin/string.mbt /home/dwp/.moon/lib/core/builtin/bigint_nonjs.mbt /home/dwp/.moon/lib/core/builtin/arraycore_nonjs.mbt /home/dwp/.moon/lib/core/builtin/array_block.mbt /home/dwp/.moon/lib/core/builtin/array.mbt /home/dwp/.moon/lib/core/builtin/linked_hash_set.mbt /home/dwp/.moon/lib/core/builtin/show.mbt /home/dwp/.moon/lib/core/builtin/unit.mbt /home/dwp/.moon/lib/core/builtin/tuple_to_json.mbt /home/dwp/.moon/lib/core/builtin/linked_hash_map.mbt /home/dwp/.moon/lib/core/builtin/tuple_eq.mbt /home/dwp/.moon/lib/core/builtin/failure.mbt /home/dwp/.moon/lib/core/builtin/console.mbt /home/dwp/.moon/lib/core/builtin/fixedarray_block.mbt /home/dwp/.moon/lib/core/builtin/arrayview.mbt /home/dwp/.moon/lib/core/builtin/double_to_int64_wasm.mbt /home/dwp/.moon/lib/core/builtin/byte.mbt -o /home/dwp/.moon/lib/core/target/wasm-gc/release/bundle/builtin/builtin.core -pkg moonbitlang/core/builtin -pkg-sources moonbitlang/core/builtin:/home/dwp/.moon/lib/core/builtin -target wasm-gc

error: failed to compile core, exit code 255

System info

Linux version 5.15.167.4-microsoft-standard-WSL2 (root@f9c826d3017f) (gcc (GCC) 11.2.0, GNU ld (GNU Binutils) 2.37) #1 SMP Tue Nov 5 00:21:55 UTC 2024

@dwpeng
Copy link

dwpeng commented Jan 8, 2025

I fixed this issue by reinstalling moon cli. It looks like the old moon-cli can't complie latest core lib.

~ sudo curl -fsSL https://cli.moonbitlang.cn/install/unix.sh | bash
Downloading moonbit ...
######################################################################## 100.0%
Downloading core ...
######################################################################## 100.0%
Bundling core ...
Finished. moon: ran 47 tasks, now up to date
Finished. moon: ran 47 tasks, now up to date
Finished. moon: ran 47 tasks, now up to date
Finished. moon: ran 47 tasks, now up to date
moonbit was installed successfully to ~/.moon
To verify the downloaded binaries, check https://www.moonbitlang.com/download#verifying-binaries for instructions.
To know how to add shell completions, run 'moon shell-completion --help'
Run 'moon help' to get started
➜  ~ moon version
moon 0.1.20250107 (099c4c7 2025-01-07)

@lvyuemeng
Copy link
Author

I fixed this issue by reinstalling moon cli. It looks like the old moon-cli can't complie latest core lib.

It's related to non-ascii username in windows, I managed to tackle this by changing it, but it was painful because there's no one-click way to do this.

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

No branches or pull requests

3 participants