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

Does it work with anaconda python? #41

Closed
tkossak opened this issue Sep 23, 2017 · 6 comments
Closed

Does it work with anaconda python? #41

tkossak opened this issue Sep 23, 2017 · 6 comments

Comments

@tkossak
Copy link

tkossak commented Sep 23, 2017

$ hatch new test
Created project `test`
Creating its own virtual env... Traceback (most recent call last):
  File "/home/kossak/anaconda3/lib/python3.6/site-packages/virtualenv.py", line 2328, in <module>
    main()
  File "/home/kossak/anaconda3/lib/python3.6/site-packages/virtualenv.py", line 713, in main
    symlink=options.symlink)
  File "/home/kossak/anaconda3/lib/python3.6/site-packages/virtualenv.py", line 945, in create_environment
    download=download,
  File "/home/kossak/anaconda3/lib/python3.6/site-packages/virtualenv.py", line 901, in install_wheel
    call_subprocess(cmd, show_stdout=False, extra_env=env, stdin=SCRIPT)
  File "/home/kossak/anaconda3/lib/python3.6/site-packages/virtualenv.py", line 797, in call_subprocess
    % (cmd_desc, proc.returncode))
OSError: Command /tmp/1/test/venv/bin/python3.6 - setuptools pip wheel failed with error code 1
complete!
Installing locally in the virtual env... complete!

I use Linux Manjaro

$ python -VV
Python 3.6.2 | packaged by conda-forge | (default, Jul 23 2017, 22:59:30)
[GCC 4.8.2 20140120 (Red Hat 4.8.2-15)]

$ python3 -VV
Python 3.6.2 | packaged by conda-forge | (default, Jul 23 2017, 22:59:30)
[GCC 4.8.2 20140120 (Red Hat 4.8.2-15)]

@ofek
Copy link
Sponsor Collaborator

ofek commented Sep 23, 2017

I use Conda exclusively and have not experienced this myself. Can you please try conda update virtualenv using the same env you installed Hatch with? So if you didn't install it globally but rather in a Conda env named testing, the command would be conda update -n testing virtualenv. conda/conda#1367 (comment)

Please let me know right away how this works!

@tkossak
Copy link
Author

tkossak commented Sep 23, 2017

It is installed globally using pip, not conda (if it makes any difference?):

$ virtualenv --version
15.1.0

$ conda update virtualenv

PackageNotInstalledError: Package is not installed in prefix.
  prefix: /home/kossak/anaconda3
  package name: virtualenv

$ which virtualenv
/home/kossak/anaconda3/bin/virtualenv

$ pip install -U virtualenv
Requirement already up-to-date: virtualenv in /home/kossak/anaconda3/lib/python3.6/site-packages

$ which pip
/home/kossak/anaconda3/bin/pip

@ofek
Copy link
Sponsor Collaborator

ofek commented Sep 23, 2017

@tkossak Please try conda install virtualenv now.

@ofek
Copy link
Sponsor Collaborator

ofek commented Sep 23, 2017

@tkossak Did it work?

@tkossak
Copy link
Author

tkossak commented Sep 24, 2017

Yes, it did work, thank you. Wonder why it had problems with pip version of virtualenv.

$ conda install virtualenv
Fetching package metadata ...........
Solving package specifications: .

Package plan for installation in environment /home/kossak/anaconda3:

The following NEW packages will be INSTALLED:

    virtualenv: 15.1.0-py36_0 conda-forge

Proceed ([y]/n)? y

virtualenv-15. 100% |################################| Time: 0:00:02 660.69 kB/s

$ hatch new pkg
Created project `pkg`
Creating its own virtual env... copying /home/kossak/anaconda3/bin/python3.6 => /tmp/1/pkg/venv/bin/python3.6
copying /home/kossak/anaconda3/bin/../lib/libpython3.6m.so.1.0 => /tmp/1/pkg/venv/lib/libpython3.6m.so.1.0
complete!
Installing locally in the virtual env... complete!

@tkossak tkossak closed this as completed Sep 24, 2017
@ofek
Copy link
Sponsor Collaborator

ofek commented Sep 24, 2017

@tkossak Yay!!! It's a complicated issue with conda/virtualenv interaction conda/conda#1367 (comment) that Conda remedied with their own patch here conda/conda#1367 (comment)

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

No branches or pull requests

2 participants