Xtian Simon
2018-06-22 23:12:57 UTC
I'm working on laptop running Arch Linux with Zsh. My dev laptop has a
working system-wide installation of Python 3 installed with Arch's Pacman
package manager.
I just installed Conda from Anaconda.com, because I want to test the
Anaconda environment I'm deploying at work (Windows) and I need a package
not available on Arch (nor Conda)
*Install Miniconda*
- Installed Miniconda into my ~/home user account.
- Conda install ipython, ipykernel, and their associated packages.
- Created a new conda environment
- PIP installed a package from pypi
- Added . /home/.../conda.sh to my .zshenv according to this post
<http://I just installed Conda from Anaconda.com because I want to test the
Anaconda environment I'm deploying at work (Windows).>.
*Next*
Running Jupyter Notebook for the first time from my conda environment, the
special package I installed with PIP was not found.
Google seach shows many pages about Running
<https://dev.widemeadows.de/2017/08/23/use-your-conda-environment-in-jupyter-notebooks/>
Jupyter
<https://towardsdatascience.com/environment-management-with-conda-python-2-3-b9961a8a5097>
Notebooks <https://stackoverflow.com/a/38880722/343215> in Conda.
<https://stackoverflow.com/a/44786736/343215>
- Conda install nb_conda
*Finally*
When I click on Conda tab in Jupyter notebook, I get the error: *An error
occurred while retrieving package information. *
*Troubleshooting*
According to a post
<https://stackoverflow.com/questions/40114639/jupyter-conda-tab-an-error-occurred-while-retrieving-package-information/trackback/>
and a github issue
<https://github.com/Anaconda-Platform/nb_conda/issues/23#issuecomment-239813091>
- jupyter serverextension disable nb_conda
-
jupyter serverextension enable nb_conda
*Is there anything else I should try before I open a ticket on github?*
*Here are some system details and error output from ipykernel in the
console*
+++
$ jupyter serverextension list
config dir: /home/myusername/bin.x/miniconda3/envs/rbca/etc/jupyter
nb_conda enabled
nbpresent enabled
nb_anacondacloud enabled
+++
jupyter nbextension list
Known nbextensions:
config dir: /home/myusername/bin.x/miniconda3/envs/rbca/etc/jupyter/
nbconfig
notebook section
jupyter-js-widgets/extension enabled
nbpresent/js/nbpresent.min enabled
nb_conda/main enabled
tree section
nb_conda/tree enabled
+++
$ conda info -a
active environment : rbca
active env location : /home/myusername/bin.x/miniconda3/envs/rbca
shell level : 1
user config file : /home/myusername.condarc
populated config files :
conda version : 4.5.4
conda-build version : not installed
python version : 3.6.5.final.0
base environment : /home/myusername/bin.x/miniconda3 (writable)
channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/free/linux-64
https://repo.anaconda.com/pkgs/free/noarch
https://repo.anaconda.com/pkgs/r/linux-64
https://repo.anaconda.com/pkgs/r/noarch
https://repo.anaconda.com/pkgs/pro/linux-64
https://repo.anaconda.com/pkgs/pro/noarch
package cache : /home/myusername/bin.x/miniconda3/pkgs
/home/myusername.conda/pkgs
envs directories : /home/myusername/bin.x/miniconda3/envs
/home/myusername.conda/envs
platform : linux-64
user-agent : conda/4.5.4 requests/2.18.4 CPython/3.6.5 Linux/
4.14.49-1-lts arch/ glibc/2.27
UID:GID : 1000:1000
netrc file : None
offline mode : False
# conda environments:
#
base /home/myusername/bin.x/miniconda3
rbca * /home/myusername/bin.x/miniconda3/envs/rbca
sys.version: 3.6.5 |Anaconda, Inc.| (default, Apr 29 ...
sys.prefix: /home/myusername/bin.x/miniconda3
sys.executable: /home/myusername/bin.x/miniconda3/bin/python
conda location: /home/myusername/bin.x/miniconda3/lib/python3.6/site-
packages/conda
conda-build: None
conda-env: /home/myusername/bin.x/miniconda3/bin/conda-env
user site dirs:
CIO_TEST: <not set>
CONDA_DEFAULT_ENV: rbca
CONDA_EXE: /home/myusername/bin.x/miniconda3/bin/conda
CONDA_PREFIX: /home/myusername/bin.x/miniconda3/envs/rbca
CONDA_PROMPT_MODIFIER: (rbca)
CONDA_PYTHON_EXE: /home/myusername/bin.x/miniconda3/bin/python
CONDA_ROOT: /home/myusername/bin.x/miniconda3
CONDA_SHLVL: 1
MOZ_PLUGIN_PATH: /usr/lib/mozilla/plugins
PATH: /home/myusername/bin.x/miniconda3/envs/rbca/bin:/home/myusernamebin.x:
/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/
vendor_perl:/usr/bin/core_perl
REQUESTS_CA_BUNDLE: <not set>
SSL_CERT_FILE: <not set>
WINDOWPATH: 1
WARNING: could not import _license.show_info
# try:
# $ conda install -n root _license
+++
Inside the running jupyter kernel console I see these errors
[E 18:10:34.072 NotebookApp] Uncaught exception GET /conda/environments?_=
1529705408327 (::1)
HTTPServerRequest(protocol='http', host='localhost:8888', method='GET',
uri='/conda/environments?_=1529705408327', version='HTTP/1.1', remote_ip=
'::1')
Traceback (most recent call last):
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 1541, in _execute
result = method(*self.path_args, **self.path_kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 2949, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/notebook/base/handlers.py"
, line 677, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/handlers.py"
, line 51, in get
self.finish(json.dumps(self.env_manager.list_envs()))
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/envmanager.py"
, line 67, in list_envs
info = self.clean_conda_json(self._execute('conda info --json'))
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/envmanager.py"
, line 53, in _execute
output = check_output(cmdline)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 336, in check_output
**kwargs).stdout
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 403, in run
with Popen(*popenargs, **kwargs) as process:
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 709, in __init__
restore_signals, start_new_session)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 1344, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'conda': 'conda'
[W 18:10:34.077 NotebookApp] Unhandled error
[E 18:10:34.078 NotebookApp] {
"Host": "localhost:8888",
"Connection": "keep-alive",
"Accept": "application/json, text/javascript, */*; q=0.01",
"X-Requested-With": "XMLHttpRequest",
"X-Xsrftoken":
"2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861",
"User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36",
"Referer": "http://localhost:8888/tree",
"Accept-Encoding": "gzip, deflate, br",
"Accept-Language": "en-US,en;q=0.9",
"Cookie": "_xsrf=2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861;
username-localhost-8888=\"2|1:0|10:1529705408|23:username-localhost-8888|44:ZTlkMTdiNjg3NmJiNGQwMzg3MTM2NGIzYjAwYTNmMTk=|80f0fb5dd01dee5db1926864352653863c7c4d7584d9f0aa21f736312db61726\""
}
[E 18:10:34.078 NotebookApp] 500 GET /conda/environments?_=1529705408327 (::
1) 10.99ms referer=http://localhost:8888/tree
[E 18:10:34.082 NotebookApp] Uncaught exception GET /conda/packages/
available?_=1529705408328 (::1)
HTTPServerRequest(protocol='http', host='localhost:8888', method='GET',
uri='/conda/packages/available?_=1529705408328', version='HTTP/1.1',
remote_ip='::1')
Traceback (most recent call last):
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 1541, in _execute
result = method(*self.path_args, **self.path_kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 2949, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/notebook/base/handlers.py"
, line 677, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/handlers.py"
, line 230, in get
data = searcher.list_available(self)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/handlers.py"
, line 213, in list_available
bufsize=4096)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 709, in __init__
restore_signals, start_new_session)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 1344, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'conda': 'conda'
[W 18:10:34.083 NotebookApp] Unhandled error
[E 18:10:34.084 NotebookApp] {
"Host": "localhost:8888",
"Connection": "keep-alive",
"Accept": "application/json, text/javascript, */*; q=0.01",
"X-Requested-With": "XMLHttpRequest",
"X-Xsrftoken":
"2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861",
"User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36",
"Referer": "http://localhost:8888/tree",
"Accept-Encoding": "gzip, deflate, br",
"Accept-Language": "en-US,en;q=0.9",
"Cookie": "_xsrf=2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861;
username-localhost-8888=\"2|1:0|10:1529705408|23:username-localhost-8888|44:ZTlkMTdiNjg3NmJiNGQwMzg3MTM2NGIzYjAwYTNmMTk=|80f0fb5dd01dee5db1926864352653863c7c4d7584d9f0aa21f736312db61726\""
}
[E 18:10:34.084 NotebookApp] 500 GET /conda/packages/available?_=
1529705408328 (::1) 4.92ms referer=http://localhost:8888/tree
working system-wide installation of Python 3 installed with Arch's Pacman
package manager.
I just installed Conda from Anaconda.com, because I want to test the
Anaconda environment I'm deploying at work (Windows) and I need a package
not available on Arch (nor Conda)
*Install Miniconda*
- Installed Miniconda into my ~/home user account.
- Conda install ipython, ipykernel, and their associated packages.
- Created a new conda environment
- PIP installed a package from pypi
- Added . /home/.../conda.sh to my .zshenv according to this post
<http://I just installed Conda from Anaconda.com because I want to test the
Anaconda environment I'm deploying at work (Windows).>.
*Next*
Running Jupyter Notebook for the first time from my conda environment, the
special package I installed with PIP was not found.
Google seach shows many pages about Running
<https://dev.widemeadows.de/2017/08/23/use-your-conda-environment-in-jupyter-notebooks/>
Jupyter
<https://towardsdatascience.com/environment-management-with-conda-python-2-3-b9961a8a5097>
Notebooks <https://stackoverflow.com/a/38880722/343215> in Conda.
<https://stackoverflow.com/a/44786736/343215>
- Conda install nb_conda
*Finally*
When I click on Conda tab in Jupyter notebook, I get the error: *An error
occurred while retrieving package information. *
*Troubleshooting*
According to a post
<https://stackoverflow.com/questions/40114639/jupyter-conda-tab-an-error-occurred-while-retrieving-package-information/trackback/>
and a github issue
<https://github.com/Anaconda-Platform/nb_conda/issues/23#issuecomment-239813091>
- jupyter serverextension disable nb_conda
-
jupyter serverextension enable nb_conda
*Is there anything else I should try before I open a ticket on github?*
*Here are some system details and error output from ipykernel in the
console*
+++
$ jupyter serverextension list
config dir: /home/myusername/bin.x/miniconda3/envs/rbca/etc/jupyter
nb_conda enabled
nbpresent enabled
nb_anacondacloud enabled
+++
jupyter nbextension list
Known nbextensions:
config dir: /home/myusername/bin.x/miniconda3/envs/rbca/etc/jupyter/
nbconfig
notebook section
jupyter-js-widgets/extension enabled
nbpresent/js/nbpresent.min enabled
nb_conda/main enabled
tree section
nb_conda/tree enabled
+++
$ conda info -a
active environment : rbca
active env location : /home/myusername/bin.x/miniconda3/envs/rbca
shell level : 1
user config file : /home/myusername.condarc
populated config files :
conda version : 4.5.4
conda-build version : not installed
python version : 3.6.5.final.0
base environment : /home/myusername/bin.x/miniconda3 (writable)
channel URLs : https://repo.anaconda.com/pkgs/main/linux-64
https://repo.anaconda.com/pkgs/main/noarch
https://repo.anaconda.com/pkgs/free/linux-64
https://repo.anaconda.com/pkgs/free/noarch
https://repo.anaconda.com/pkgs/r/linux-64
https://repo.anaconda.com/pkgs/r/noarch
https://repo.anaconda.com/pkgs/pro/linux-64
https://repo.anaconda.com/pkgs/pro/noarch
package cache : /home/myusername/bin.x/miniconda3/pkgs
/home/myusername.conda/pkgs
envs directories : /home/myusername/bin.x/miniconda3/envs
/home/myusername.conda/envs
platform : linux-64
user-agent : conda/4.5.4 requests/2.18.4 CPython/3.6.5 Linux/
4.14.49-1-lts arch/ glibc/2.27
UID:GID : 1000:1000
netrc file : None
offline mode : False
# conda environments:
#
base /home/myusername/bin.x/miniconda3
rbca * /home/myusername/bin.x/miniconda3/envs/rbca
sys.version: 3.6.5 |Anaconda, Inc.| (default, Apr 29 ...
sys.prefix: /home/myusername/bin.x/miniconda3
sys.executable: /home/myusername/bin.x/miniconda3/bin/python
conda location: /home/myusername/bin.x/miniconda3/lib/python3.6/site-
packages/conda
conda-build: None
conda-env: /home/myusername/bin.x/miniconda3/bin/conda-env
user site dirs:
CIO_TEST: <not set>
CONDA_DEFAULT_ENV: rbca
CONDA_EXE: /home/myusername/bin.x/miniconda3/bin/conda
CONDA_PREFIX: /home/myusername/bin.x/miniconda3/envs/rbca
CONDA_PROMPT_MODIFIER: (rbca)
CONDA_PYTHON_EXE: /home/myusername/bin.x/miniconda3/bin/python
CONDA_ROOT: /home/myusername/bin.x/miniconda3
CONDA_SHLVL: 1
MOZ_PLUGIN_PATH: /usr/lib/mozilla/plugins
PATH: /home/myusername/bin.x/miniconda3/envs/rbca/bin:/home/myusernamebin.x:
/usr/local/sbin:/usr/local/bin:/usr/bin:/usr/bin/site_perl:/usr/bin/
vendor_perl:/usr/bin/core_perl
REQUESTS_CA_BUNDLE: <not set>
SSL_CERT_FILE: <not set>
WINDOWPATH: 1
WARNING: could not import _license.show_info
# try:
# $ conda install -n root _license
+++
Inside the running jupyter kernel console I see these errors
[E 18:10:34.072 NotebookApp] Uncaught exception GET /conda/environments?_=
1529705408327 (::1)
HTTPServerRequest(protocol='http', host='localhost:8888', method='GET',
uri='/conda/environments?_=1529705408327', version='HTTP/1.1', remote_ip=
'::1')
Traceback (most recent call last):
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 1541, in _execute
result = method(*self.path_args, **self.path_kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 2949, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/notebook/base/handlers.py"
, line 677, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/handlers.py"
, line 51, in get
self.finish(json.dumps(self.env_manager.list_envs()))
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/envmanager.py"
, line 67, in list_envs
info = self.clean_conda_json(self._execute('conda info --json'))
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/envmanager.py"
, line 53, in _execute
output = check_output(cmdline)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 336, in check_output
**kwargs).stdout
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 403, in run
with Popen(*popenargs, **kwargs) as process:
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 709, in __init__
restore_signals, start_new_session)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 1344, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'conda': 'conda'
[W 18:10:34.077 NotebookApp] Unhandled error
[E 18:10:34.078 NotebookApp] {
"Host": "localhost:8888",
"Connection": "keep-alive",
"Accept": "application/json, text/javascript, */*; q=0.01",
"X-Requested-With": "XMLHttpRequest",
"X-Xsrftoken":
"2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861",
"User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36",
"Referer": "http://localhost:8888/tree",
"Accept-Encoding": "gzip, deflate, br",
"Accept-Language": "en-US,en;q=0.9",
"Cookie": "_xsrf=2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861;
username-localhost-8888=\"2|1:0|10:1529705408|23:username-localhost-8888|44:ZTlkMTdiNjg3NmJiNGQwMzg3MTM2NGIzYjAwYTNmMTk=|80f0fb5dd01dee5db1926864352653863c7c4d7584d9f0aa21f736312db61726\""
}
[E 18:10:34.078 NotebookApp] 500 GET /conda/environments?_=1529705408327 (::
1) 10.99ms referer=http://localhost:8888/tree
[E 18:10:34.082 NotebookApp] Uncaught exception GET /conda/packages/
available?_=1529705408328 (::1)
HTTPServerRequest(protocol='http', host='localhost:8888', method='GET',
uri='/conda/packages/available?_=1529705408328', version='HTTP/1.1',
remote_ip='::1')
Traceback (most recent call last):
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 1541, in _execute
result = method(*self.path_args, **self.path_kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/tornado/web.py"
, line 2949, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/notebook/base/handlers.py"
, line 677, in wrapper
return method(self, *args, **kwargs)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/handlers.py"
, line 230, in get
data = searcher.list_available(self)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/site-packages/nb_conda/handlers.py"
, line 213, in list_available
bufsize=4096)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 709, in __init__
restore_signals, start_new_session)
File
"/home/myusername/bin.x/miniconda3/envs/rbca/lib/python3.6/subprocess.py",
line 1344, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'conda': 'conda'
[W 18:10:34.083 NotebookApp] Unhandled error
[E 18:10:34.084 NotebookApp] {
"Host": "localhost:8888",
"Connection": "keep-alive",
"Accept": "application/json, text/javascript, */*; q=0.01",
"X-Requested-With": "XMLHttpRequest",
"X-Xsrftoken":
"2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861",
"User-Agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36
(KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36",
"Referer": "http://localhost:8888/tree",
"Accept-Encoding": "gzip, deflate, br",
"Accept-Language": "en-US,en;q=0.9",
"Cookie": "_xsrf=2|186a620b|3b31c6959a7460640a4ba10ea7e504de|1528939861;
username-localhost-8888=\"2|1:0|10:1529705408|23:username-localhost-8888|44:ZTlkMTdiNjg3NmJiNGQwMzg3MTM2NGIzYjAwYTNmMTk=|80f0fb5dd01dee5db1926864352653863c7c4d7584d9f0aa21f736312db61726\""
}
[E 18:10:34.084 NotebookApp] 500 GET /conda/packages/available?_=
1529705408328 (::1) 4.92ms referer=http://localhost:8888/tree
--
You received this message because you are subscribed to the Google Groups "conda - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to conda+***@continuum.io.
To post to this group, send email to ***@continuum.io.
Visit this group at https://groups.google.com/a/continuum.io/group/conda/.
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/conda/3c664cf9-1191-4d68-b248-9cd220bf5af8%40continuum.io.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.
You received this message because you are subscribed to the Google Groups "conda - Public" group.
To unsubscribe from this group and stop receiving emails from it, send an email to conda+***@continuum.io.
To post to this group, send email to ***@continuum.io.
Visit this group at https://groups.google.com/a/continuum.io/group/conda/.
To view this discussion on the web visit https://groups.google.com/a/continuum.io/d/msgid/conda/3c664cf9-1191-4d68-b248-9cd220bf5af8%40continuum.io.
For more options, visit https://groups.google.com/a/continuum.io/d/optout.