-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
[Modular CLI]: M2 Mac air , fail to install new mojo even afeter clean modular/old mojo. Encounter modular: error: Error extracting /: Can't remove already-existing dir #1912
Comments
@zbowling any update? Is that any extra information I could provide to boost the process? |
Can you run |
same here. re run both still encounter same error. |
can you tell me what version of modular you are running with |
Also one thing we can try if you are willing to do an experiment for me is to run this and see if that works?
That forces a deprecated package download method that is still used on older packages and is going away soon. We are not seeing this error with high frequency but I'm still curious if that method works for you. |
@zbowling Thanks! This way with addition flag works. |
@zbowling . Add flag works! However, I still use modular 0.5.1 to test it first. Many thanks! Let's close the issue. |
Could it be because mojo doesn't support rye?
Env:
❯ which python
/Users/dev/.rye/shims/python
❯ python -V
Python 3.12.2 Error logs:modular clean && modular install mojo --force-cas
# Found release for https://packages.modular.com/mojo @ 24.1.1-0ab415f7-release
# Collecting necessary files...
[files 124/124][bytes 118MiB/118MiB @ 10.5MiB/s][██████████████████████████████] 💯%
# Downloads complete, setting configs...
# Configs complete, running post-install hooks...
Traceback (most recent call last):
File "/Users/dev/.modular/pkg/packages.modular.com_mojo/scripts/post-install/pick_python.py", line 67, in <module>
main()
File "/Users/dev/.modular/pkg/packages.modular.com_mojo/scripts/post-install/pick_python.py", line 50, in main
raise Exception(
Exception: Could not find libpython. Check your Python installation and ensure that $LD_LIBRARY_PATH includes the location to the installed Python library (e.g. /usr/lib/x86_64-linux-gnu).
modular: error: failed to run script
==========================
Failure Information:
- Script: `PATH=/Users/dev/.pyenv/bin:/opt/homebrew/opt/llvm/bin:/Users/dev/.rye/shims:/Users/dev/google-cloud-sdk/bin:/Users/dev/Library/pnpm:/Users/dev/.cargo/bin:/Users/dev/Library/Caches/fnm_multishells/70445_1710899384616/bin:/Users/dev/.pyenv/shims:/bin:/sbin:/usr/bin:/usr/sbin:/usr/local/opt/llvm/bin:/usr/local/bin:/Library/Apple/usr/bin:/opt/homebrew/sbin:/opt/homebrew/bin:/Users/dev/bin:/Users/dev/.local/bin:/Applications/IntelliJ IDEA.app/Contents/plugins/maven/lib/maven3/bin:/Applications/Little Snitch.app/Contents/Components:/Applications/Visual Studio Code.app/Contents/Resources/app/bin:~/.fig/bin:~/.fnm:~/.cargo/bin:~/.local/bin:~/.yarn/bin:~/.pulumi/bin:/Users/dev/go/bin:~/sdk/android/emulator:~/sdk/android/tools:~/sdk/android/tools/bin:~/sdk/android/platform-tools:/Users/dev/Library/Android/sdk/emulator:/Users/dev/Library/Android/sdk/tools:/Users/dev/Library/Android/sdk/tools/bin:/Users/dev/Library/Android/sdk/platform-tools:/Users/dev/.gem/bin:/Users/dev/.modular/pkg/packages.modular.com_mojo/bin:~/.pyenv/bin:~/.pyenv/shims:~/.pyenv/plugins/pyenv-virtualenv/shims:/usr/local/share/dotnet/:/usr/local/share/dotnet//tools:/Users/dev/.pub-cache/bin:/Users/dev/.fvm/default/bin:/Users/dev/.fvm/default/bin/cache/dart-sdk/bin HOME=/Users/dev MODULAR_HOME=/Users/dev/.modular PYTHONPATH=/Users/dev/.modular/pkg/packages.modular.com_mojo/venv/lib/Users/dev/.modular/pkg/packages.modular.com_mojo/venv/bin/python /Users/dev/.modular/pkg/packages.modular.com_mojo/scripts/post-install/pick_python.py -installer-outfile /var/folders/pc/78th99qs10zfzdx_r683t23w0000gn/T/modular-tool-script-redirect-7e8791.tmp`
- Result: 1
- Stderr:
Traceback (most recent call last):
File "/Users/dev/.modular/pkg/packages.modular.com_mojo/scripts/post-install/pick_python.py", line 67, in <module>
main()
File "/Users/dev/.modular/pkg/packages.modular.com_mojo/scripts/post-install/pick_python.py", line 50, in main
raise Exception(
Exception: Could not find libpython. Check your Python installation and ensure that $LD_LIBRARY_PATH includes the location to the installed Python library (e.g. /usr/lib/x86_64-linux-gnu).
========================== |
Related:
$HOME/.rye/py/cpython@3.12.2
export LD_LIBRARY_PATH="/Users/dev/.rye/py/cpython@3.12.2/install/lib/"
export LD_LIBRARY_PATH="/Users/dev/.rye/py/cpython@3.12.2/lib/libpython3.12.dylib"
![]() Temporary Solution:
❯ which python
/Users/dev/.pyenv/shims/python
~ on ☁️
❯ python --version | awk '{print $2}'
3.10.6
~ on ☁️
❯ modular clean && modular install mojo --force-cas
# Found release for https://packages.modular.com/mojo @ 24.1.1-0ab415f7-release
# Collecting necessary files...
[files 124/124][bytes 118MiB/118MiB @ 21KiB/s][██████████████████████████████] 💯%
# Downloads complete, setting configs...
# Configs complete, running post-install hooks...
🔥 Mojo installed! 🔥
Mojo's Python virtual environment created at /Users/dev/.modular/pkg/packages.modular.com_mojo/venv
If you are using ZSH (default on macOS), run the following commands:
echo 'export MODULAR_HOME="/Users/dev/.modular"' >> ~/.zshrc
echo 'export PATH="/Users/dev/.modular/pkg/packages.modular.com_mojo/bin:$PATH"' >> ~/.zshrc
source ~/.zshrc
If you are using bash, run the following commands:
BASHRC=$( [ -f "$HOME/.bash_profile" ] && echo "$HOME/.bash_profile" || echo "$HOME/.bashrc" )
echo 'export MODULAR_HOME="/Users/dev/.modular"' >> "$BASHRC"
echo 'export PATH="/Users/dev/.modular/pkg/packages.modular.com_mojo/bin:$PATH"' >> "$BASHRC"
source "$BASHRC"
Then enter 'mojo' to start the Mojo REPL.
For tool help, enter 'mojo --help'.
For more docs, see https://docs.modular.com/mojo.
![]() |
@hhstore I don't think I've tested with Rye. Can you copy your comments to a different bug and open it? It's a different issue than this one and then I can add it to the right team's triage queue. |
|
Issue description
As ttile, While I try to update mojo to 24.1 from 0.7.0. It works fine with older version.
Steps to reproduce
Version Info
The text was updated successfully, but these errors were encountered: