Skip to content
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

When installing install-dev.sh in macOS environment, if pyenv is not installed, the installation will not be completed. #211

Open
zel0rd opened this issue Aug 26, 2020 · 3 comments

Comments

@zel0rd
Copy link

@zel0rd zel0rd commented Aug 26, 2020

Describe the bug

  • When running scripts/install-dev.sh on macOS, if pyenv and virtualenv are not installed, the installation cannot be completed.

To Reproduce

  1. [Setting same environment] brew uninstall pyenv / brew uninstall pyenv-virtualenv
  2. [execute scripts/install-dev.sh] ./install-dev.sh
  3. [See error1] WARNING: Can not proceed with installation. Kindely remove the '/User/./.pyenv' directory first.
  4. [Fix error1] brew install pyenv
  5. [See error2] [INFO] Creating virtualenv on pyenv... / pyenv: no such command 'virtualenv'
  6. [Fix error2] brew install pyenv-virtualenv

Expected behavior
If pyenv or pyenv-virtual is not installed, automatically install it using brew.

Screenshots
issue_when_not_installed_pyenv
issue_when_not_installed_virtualenv

Additional context

  • I will be revising pyenv and pyenv-virtual within this week so that they can be automatically installed.
@zel0rd zel0rd added the bug label Aug 26, 2020
@zel0rd
Copy link
Author

@zel0rd zel0rd commented Aug 26, 2020

@achimnol
Copy link
Member

@achimnol achimnol commented Aug 28, 2020

The root problem is here: between your reproduction step 4 and 5, there is a missing step.
You must (re-)initialize pyenv for your current shell, by executing exec "$(pyenv init -)" or restarting the shell after setting up your shell configuration such as .bashrc, .bash_profile, .profile, etc. as guided by the pyenv manual.

@achimnol
Copy link
Member

@achimnol achimnol commented Aug 28, 2020

The correct fix would be to improve the error messages, so that users can properly "reinstall both pyenv and pyenv-virtualenv" and/or "fix the shell config", not to silenty brew-uninstall as in #212. Since pyenv could be installed in many ways (git clone / brew / etc.) we should leave the users the concrete method to do so.
Please rewrite #212.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.