is it possible to run the terminal through rosetta for arm?
Answered
I have mac with arm, and the arm version of vs code. However, many of the packages don't work native. I have gotten everything up and running running the mac terminal through rosetta, but don't see an option to run the vs code terminal through rosetta on it's own. Is that possible?
Please sign in to leave a comment.
Hi Jason,
This is the PyCharm forum, not VS Code.
Please contact the VS Code team using one of the options mentioned in their documentation https://code.visualstudio.com/docs/supporting/faq#_technical-support
Sergey Karpov
Sorry about that. I've been trying to get either to work, and misspoke. Is it possible for PC?
You can configure terminal shell in Preferences | Tools | Terminal like you do normally to run it in Rosetta.
Who ever lands here via Google, set the "shell path" under preferences - tools - terminal:
Serge, can you confirm how you do this through Preferences | Tools | Terminal? I’m not seeing an option for Rosetta / ARM.
redaxmedia solution worked perfectly. Could you help me understand what the lines are doing? How does the env command work?
The solution of redaxmedia didn't work for me, but creating a Shell Script Run Configuration using a Script text did the job for me:
env /usr/bin/arch -x86_64 /bin/zsh -c "python3 -m my_package"
Edit - Changing the terminal also applied for the test runner
Thanks redaxmedia, I can now start the terminal with arch==i386. How can I do the same when using PyCharm run command (for example to run tests)?
I used redaxmedia solution, the terminal works fine, but PyChram is not enabling my Python virtual environment.
instead of:
any ideas on how to fix it?
Thanks
Slanton I am running
Change shell path to "env /usr/bin/arch -x86_64 /bin/zsh" seems to solves the issue (allowing using zsh and activating the virtual env)
I used redaxmedia solution, it worked, but I also had the problem with virtualenv not being activated automatically. However, I noticed that
$VIRTUAL_ENV
variable gets populated by PyCharm, so I added the following to~/.zshrc
: