Hi guys, Trying to follow the guide to contribute ...
# ask-community
s
Hi guys, Trying to follow the guide to contribute to dagster. However, just switched to a macOS Monterey. Whenever i try to pyenv install 3.7.4 i get the attached error. Tried all solutions marked as working on Google as of now. Any suggestions? Much appreciated
d
Did you try to install a more recent version as well?
s
A more recent python version? pyenv install 3.10.3 fails with the following error instead: symbol(s) not found for architecture arm64
d
and 3.9/3.8?
s
3.9 gives the inital error and 3.8 gives the above error about symbols 😄
d
can you install clang?
it looks like you are missing a compiler
s
I had enough, Bypassed the issue by downloading the required python version manually and used virtualenv to create a virtualenv manually 🙂 That'll do
j
Hi @Simon Kragh! does your computer have an M1 chip? if so you'll need to do some initial setup because M1 has an arm architecture instead of x86. I can send along some resources if that's the case for you
s
It does @jamie! Thanks!
j
ok! First you'll want to set up a terminal to default to run with rosetta (the top answer to this stack exchange goes over how to do that). Then you'll install homebrew in the rosetta terminal using the command
arch -x86_64 /bin/bash -c "$(curl -fsSL <https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh>)"
. You'll also need to know which version of homebrew to use depending on if you're in your rosetta terminal or arm terminal (assuming you've also installed homebrew for arm). You can alias the installations like this
Copy code
alias ibrew='arch -x86_64 /usr/local/bin/brew'
alias mbrew='arch -arm64e /opt/homebrew/bin/brew'
or add this snippet to your
~/.bashrc
or
~/.zshrc
Copy code
arch_name="$(uname -m)"

if [ "${arch_name}" = "x86_64" ]; then
    echo "Running in x86 mode"
    eval $(/usr/local/bin/brew shellenv)
    
elif [ "${arch_name}" = "arm64" ]; then
    echo "Running in Arm mode"
    eval $(/opt/homebrew/bin/brew shellenv)
    
else
    echo "Unexpected uname -m result ${arch_name}"
fi


# brew libraries
export LDFLAGS="-L $(brew --prefix openssl)/lib"
export CFLAGS="-I $(brew --prefix openssl)/include"
From there you should be able to follow the rest of the instructions in our docs in your rosetta terminal, but let me know if something still isn't working!