I tried to install anaconda to install the data analysis library all at once, but when I run pip or python commands while trying to install anaconda with pyenv (a package that can switch between multiple versions of Python), an infinite loop occurs. It has occurred. I looked it up in "pyenv infinite loop" etc. and also referred to posted by a_yasui, but at the beginning of .bash_profile
PATH=$PATH:~/.pyenv/shims/
if which pyenv > /dev/null; then eval "$(pyenv init -)"; fi
I added and checked .bashrc, so I guessed something else was wrong.
OS: Mac OSX El Capitan 10.11.3 Execution environment: Mac standard Terminal Confirmed with pyenv: Build 20151210, 20160202
As a symptom, when I execute the pip command etc., the command loops like bash → readlink → bash, and the execution does not proceed. The solution was to install __Python with the pyenv install command and apply python with pyenv local orz __. First,
>> which python
/Users/user/.pyenv/shims/python
>> which pip
/Users/user/.pyenv/shims/pip
However, when I enter the pyenv version command,
>> pyenv version
system (set by /Users/user/.pyenv/version)
I noticed that "Oh, I didn't put Python in pyenv" because it was displayed only.
// >> pyenv install -You can check the installable version with l
>> pyenv install Python3.5.0 //Python installation
>> pyenv rehash //Refresh pyenv
>> pyenv local Python3.5.0 //Apply python
>> pyenv global Python3.5.0 //Apply python
I typed and changed the python to use and then ran the pip, python commands and it worked. Probably, I imagine that there is a problem if system python is used for python used in the environment of pyenv (/Users/user/.pyenv/).
It may be a symptom that is not reproducible, and I think that it is a general mistake because I used pyenv without understanding it well, but if you happen to have a similar symptom, Python used in pyenv Try to see if is not for system. We hope for your reference.
pyenv local system
pyenv global system
pip
When I typed and executed pip etc., the infinite loop was reproduced. I hope it happens only in my environment ...
appendix
The reason why I noticed that python doesn't work in the first place is that I am using SublimeCodeIntel and looking at the log.
evaluating 'str' at hoge.py#37: no Python scan info for <Python buf 'hoge.py'>
done eval: eval error
Was output. When I wondered if python was wrong and ran python on the terminal, the above symptom was discovered.