Python Forum
pipenv install command getting errors on WSL/Ubuntu - Printable Version

+- Python Forum (https://python-forum.io)
+-- Forum: Python Coding (https://python-forum.io/forum-7.html)
+--- Forum: General Coding Help (https://python-forum.io/forum-8.html)
+--- Thread: pipenv install command getting errors on WSL/Ubuntu (/thread-12810.html)



pipenv install command getting errors on WSL/Ubuntu - sheridanrea - Sep-14-2018

I am new to python development. I am using Python 3.5 and have installed pip and pipenv successfully. I am working on a terminal with WSL/Ubuntu. I am starting a new project and trying to run the command
pipenv install requests

This is output I get from that command:

Output:
Creating a virtualenv for this project... Pipfile: /c/Users/Sheridan/Documents/Arbor/CFCReferralsTool/cfc-referrals-tool/Pipfile Using /home/srea/anaconda3/bin/python (3.5.3) to create virtualenv... â ™Already using interpreter /home/srea/anaconda3/bin/python Using base prefix '/home/srea/anaconda3' New python executable in /home/srea/.local/share/virtualenvs/cfc-referrals-tool-H3Na6Dpb/bin/python Installing setuptools, pip, wheel... Complete output from command /home/srea/.local/sh...-H3Na6Dpb/bin/python - setuptools pip wheel: Traceback (most recent call last): File "<stdin>", line 3, in <module> File "/home/srea/anaconda3/lib/python3.5/pkgutil.py", line 3, in <module> from functools import singledispatch as simplegeneric File "/home/srea/.local/share/virtualenvs/cfc-referrals-tool-H3Na6Dpb/lib/python3.5/functools.py", line 23, in <module> from weakref import WeakKeyDictionary File "/home/srea/.local/share/virtualenvs/cfc-referrals-tool-H3Na6Dpb/lib/python3.5/weakref.py", line 12, in <module> from _weakref import ( ImportError: cannot import name '_remove_dead_weakref' ---------------------------------------- ...Installing setuptools, pip, wheel...done. Traceback (most recent call last): File "/home/srea/anaconda3/lib/python3.5/runpy.py", line 193, in _run_module_as_main "__main__", mod_spec) File "/home/srea/anaconda3/lib/python3.5/runpy.py", line 85, in _run_code exec(code, run_globals) File "/home/srea/anaconda3/lib/python3.5/site-packages/virtualenv.py", line 2343, in <module> main() File "/home/srea/anaconda3/lib/python3.5/site-packages/virtualenv.py", line 712, in main symlink=options.symlink) File "/home/srea/anaconda3/lib/python3.5/site-packages/virtualenv.py", line 947, in create_environment download=download, File "/home/srea/anaconda3/lib/python3.5/site-packages/virtualenv.py", line 904, in install_wheel call_subprocess(cmd, show_stdout=False, extra_env=env, stdin=SCRIPT) File "/home/srea/anaconda3/lib/python3.5/site-packages/virtualenv.py", line 796, in call_subprocess % (cmd_desc, proc.returncode)) OSError: Command /home/srea/.local/sh...-H3Na6Dpb/bin/python - setuptools pip wheel failed with error code 1 Virtualenv location: Creating a Pipfile for this project... Traceback (most recent call last): File "/home/srea/.local/bin/pipenv", line 11, in <module> sys.exit(cli()) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/vendor/click/core.py", line 722, in __call__ return self.main(*args, **kwargs) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/vendor/click/core.py", line 697, in main rv = self.invoke(ctx) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/vendor/click/core.py", line 1066, in invoke return _process_result(sub_ctx.command.invoke(sub_ctx)) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/vendor/click/core.py", line 895, in invoke return ctx.invoke(self.callback, **ctx.params) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/vendor/click/core.py", line 535, in invoke return callback(*args, **kwargs) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/cli.py", line 435, in install selective_upgrade=selective_upgrade, File "/home/srea/.local/lib/python3.5/site-packages/pipenv/core.py", line 1759, in do_install pypi_mirror=pypi_mirror, File "/home/srea/.local/lib/python3.5/site-packages/pipenv/core.py", line 639, in ensure_project ensure_pipfile(validate=validate, skip_requirements=skip_requirements, system=system) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/core.py", line 288, in ensure_pipfile project.create_pipfile(python=python) File "/home/srea/.local/lib/python3.5/site-packages/pipenv/project.py", line 607, in create_pipfile required_python = self.which('python') File "/home/srea/.local/lib/python3.5/site-packages/pipenv/core.py", line 115, in which p = os.path.join(location, 'bin', command) File "/home/srea/anaconda3/lib/python3.5/posixpath.py", line 89, in join genericpath._check_arg_types('join', a, *p) File "/home/srea/anaconda3/lib/python3.5/genericpath.py", line 143, in _check_arg_types (funcname, s.__class__.__name__)) from None TypeError: join() argument must be str or bytes, not 'NoneType'
I have tried uninstalling and reinstalling python, pip, and pip3 but the same error occurs. The Pipfile gets created, but is empty. Any help is appreciated!