After I upgrade python to the new version on my laptop, and when I run python I got this warning:
/Users/darm/.pyenv/shims/python3: line 21: /usr/local/Cellar/pyenv/1.2.18/libexec/pyenv: No such file or directory
To solve the issue, you have to rehash it, like below.
pyenv rehash