Jupyter lab build fail after installing plotly extension - installation
Plotly figures are not rendered/displayed in jupyterlab. I therefore tried to install the extension jupyter labextension install #jupyter-widgets/jupyterlab-manager jupyterlab-plotly. Afterwards I was asked to run the jupyter lab build and this failed. I have no idea where the problem is.
Install info:
I installed a venv with pyenv running python 3.8.5.
jupyter --version
jupyter core : 4.7.1
jupyter-notebook : 6.4.0
qtconsole : not installed
ipython : 7.25.0
ipykernel : 6.0.3
jupyter client : 6.1.12
jupyter lab : 3.0.12
nbconvert : 6.1.0
ipywidgets : 7.6.3
nbformat : 5.1.3
traitlets : 5.0.5
npm --version
7.11.2
node --version
v16.1.0
I am restricted to use WSL1 because of company requirements.
I’ll post below the command outputs for
jupyter labextension list
jupyter lab build
cat /tmp/jupyterlab-debug-5vr2zquq.log
jupyter labextension install #jupyter-widgets/jupyterlab-manager --minimize=False
Any advice would be appreciated. I have no idea how to fix this.
Thanks
❯ jupyter labextension list
JupyterLab v3.0.16
/home/bebop/.local/share/jupyter/labextensions
#jupyter-widgets/jupyterlab-manager v3.0.0 enabled OK (python, jupyterlab_widgets)
/mnt/s/dokumente/Privat/neue_fische/ot/ot-sopra_steria/.venv/share/jupyter/labextensions
jupyterlab-plotly v5.1.0 enabled OK
Other labextensions (built into JupyterLab)
app dir: /mnt/s/dokumente/Privat/neue_fische/ot/ot-sopra_steria/.venv/share/jupyter/lab
plotlywidget v4.14.3 enabled OK
Build recommended, please run jupyter lab build:
plotlywidget needs to be included in build
❯ jupyter lab build
[LabBuildApp] JupyterLab 3.0.16
[LabBuildApp] Building in /mnt/s/dokumente/Privat/path/.venv/share/jupyter/lab
[LabBuildApp] Building jupyterlab assets (production, minimized)
Build failed.
Troubleshooting: If the build failed due to an out-of-memory error, you
may be able to fix it by disabling the dev_build and/or minimize options.
If you are building via the jupyter lab build command, you can disable
these options like so:
jupyter lab build --dev-build=False --minimize=False
You can also disable these options for all JupyterLab builds by adding these
lines to a Jupyter config file named jupyter_config.py:
c.LabBuildApp.minimize = False
c.LabBuildApp.dev_build = False
If you don’t already have a jupyter_config.py file, you can create one by
adding a blank file of that name to any of the Jupyter config directories.
The config directories can be listed by running:
jupyter --paths
Explanation:
dev-build: This option controls whether a dev or a more streamlined
production build is used. This option will default to False (i.e., the
production build) for most users. However, if you have any labextensions
installed from local files, this option will instead default to True.
Explicitly setting dev-build to False will ensure that the production
build is used in all circumstances.
minimize: This option controls whether your JS bundle is minified
during the Webpack build, which helps to improve JupyterLab’s overall
performance. However, the minifier plugin used by Webpack is very memory
intensive, so turning it off may help the build finish successfully in
low-memory environments.
An error occured.
shutil.Error: [(’/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/staging/templates’, ‘/mnt/s/dokumente/Privat/path/.venv/share/jupyter/lab/staging/templates’, “[Errno 13] Permission denied: ‘/mnt/s/dokumente/Privat/path/.venv/share/jupyter/lab/staging/templates’”)]
See the log file for details: /tmp/jupyterlab-debug-5vr2zquq.log
❯ cat /tmp/jupyterlab-debug-5vr2zquq.log
[LabBuildApp] Building in /mnt/s/dokumente/Privat/path/.venv/share/jupyter/lab
[LabBuildApp] Node v16.1.0
[LabBuildApp] Yarn configuration loaded.
[LabBuildApp] Building jupyterlab assets (production, minimized)
[LabBuildApp] Traceback (most recent call last):
[LabBuildApp] File “/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/debuglog.py”, line 47, in debug_logging
yield
[LabBuildApp] File “/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/labapp.py”, line 166, in start
raise e
[LabBuildApp] File “/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/labapp.py”, line 162, in start
build(name=self.name, version=self.version,
[LabBuildApp] File “/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/commands.py”, line 469, in build
return handler.build(name=name, version=version, static_url=static_url,
[LabBuildApp] File “/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/commands.py”, line 657, in build
self._populate_staging(
[LabBuildApp] File “/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/commands.py”, line 1180, in _populate_staging
shutil.copytree(pjoin(HERE, ‘staging’, ‘templates’), templates)
[LabBuildApp] File “/home/bebop/.pyenv/versions/3.8.5/lib/python3.8/shutil.py”, line 554, in copytree
return _copytree(entries=entries, src=src, dst=dst, symlinks=symlinks,
[LabBuildApp] File “/home/bebop/.pyenv/versions/3.8.5/lib/python3.8/shutil.py”, line 510, in _copytree
raise Error(errors)
[LabBuildApp] shutil.Error: [(’/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/staging/templates’, ‘/mnt/s/dokumente/Privatpath/.venv/share/jupyter/lab/staging/templates’, “[Errno 13] Permission denied: ‘/mnt/s/dokumente/Privat/path/.venv/share/jupyter/lab/staging/templates’”)]
[LabBuildApp] Exiting application: JupyterLab
❯ jupyter labextension install #jupyter-widgets/jupyterlab-manager --minimize=False
Building jupyterlab assets (production, not minimized)
An error occured.
shutil.Error: [(’/mnt/s/dokumente/Privat/path/.venv/lib/python3.8/site-packages/jupyterlab/staging/templates’, ‘/mnt/s/dokumente/path/.venv/share/jupyter/lab/staging/templates’, “[Errno 13] Permission denied: ‘/mnt/s/dokumente/Privat/path/.venv/share/jupyter/lab/staging/templates’”)]
You should not need to install the extension from source. JupyterLab 3.0 introduced prebuilt extensions system that allows users to install extensions from pip (and conda) without the need for the build step making all the trouble of troubleshooting failed builds disappear. It seems that you used an old set of instructions for installing plotly, as plotly 5.0+ supports prebuilt extensions for JupyterLab. First uninstall the source extensions that you just installed (non of those are needed):
jupyter labextension uninstall #jupyter-widgets/jupyterlab-manager jupyterlab-plotly plotlywidget
Optional: verify list of extensions with:
jupyter labextension list
Then install a new plotly version with pip or conda:
pip install "plotly>=5" "ipywidgets>=7.6"
# or, if using conda:
# conda install -c conda "plotly>=5"
# conda install "ipywidgets>=7.6"
Both widget and renderer are included, so no need to install plotlywidget separately.
Check list of extensions again:
jupyter labextension list
You should now see lines with:
jupyterlab-plotly v5.1.0 enabled OK
#jupyter-widgets/jupyterlab-manager v3.0.0 enabled OK (python, jupyterlab_widgets)
(the version may be newer in the future of course).
Related
Installing pysam for HTSeq - "PackagesNotFoundError: The following packages are not available from current channels:"
I am new to Python, Anaconda, and coding in general. I'm trying to install pysam. I need it to install HTSeq so that I can convert bam files to count files for a class project. Once they are count files, I plan to use edgeR for the rest of the data analysis. I was able to install NumPy without a problem. I've tried multiple codes for installing pysam, so I'm wondering if I'm missing some sort of dependency? Do I need to install samtools or something before I can install pysam? In addition to tips for installing pysam, I am also open to advice for other methods for converting bam files to count files. Is it possible to download and use HTSeq for this purpose without pysam? Converting the file is the only thing I need to use HTSeq for to complete my class project. Is there another program other than HTSeq that I could use? I appreciate any advice, and sorry if I'm leaving out any critical information. This is my first big coding project and the first time I've had to ask a stack question. Thanks! Here is what I have tried to install pysam: conda config --add channels r Warning: 'r' already in 'channels' list, moving to the top conda config --add channels bioconda Warning: 'bioconda' already in 'channels' list, moving to the top conda install pysam conda install -c bioconda pysam conda install -c "bioconda/label/cf201901" pysam For every conda install I get the same output: Collecting package metadata (current_repodata.json): done Solving environment: failed with initial frozen solve. Retrying with flexible solve. Collecting package metadata (repodata.json): done Solving environment: failed with initial frozen solve. Retrying with flexible solve. PackagesNotFoundError: The following packages are not available from current channels: pysam Current channels: a bunch of links here that stack won't let me post To search for alternate channels that may provide the conda package you're looking for, navigate to https://anaconda.org and use the search bar at the top of the page. ``` ``` I also tried: conda config --append channels conda-forge Warning: 'conda-forge' already in 'channels' list, moving to the bottom And when I tried the conda install I got the same output as before. Even though it's not recommended, I also tried to install with pip using: pip install pysam Collecting pysam Using cached pysam-0.20.0.tar.gz (4.0 MB) Preparing metadata (setup.py) ... error error: subprocess-exited-with-error python setup.py egg_info did not run successfully. exit code: 1 [24 lines of output] pysam: cython is available - using cythonize if necessary pysam: htslib mode is shared pysam: HTSLIB_CONFIGURE_OPTIONS=None is not recognized as an internal or external command, operable program or batch file. is not recognized as an internal or external command, operable program or batch file. Traceback (most recent call last): File "<string>", line 2, in <module> File "<pip-setuptools-caller>", line 34, in <module> File "C:\Users\Emily\AppData\Local\Temp\pip-install-q06_8qe9\pysam_31e61bb6d116452f888986de7135a214\setup.py", line 381, in <module> htslib_make_options = run_make_print_config() File "C:\Users\Emily\AppData\Local\Temp\pip-install-q06_8qe9\pysam_31e61bb6d116452f888986de7135a214\setup.py", line 79, in run_make_print_config stdout = subprocess.check_output(["make", "-s", "print-config"]) File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 424, in check_output return run(*popenargs, stdout=PIPE, timeout=timeout, check=True, File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 505, in run with Popen(*popenargs, **kwargs) as process: File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 951, in __init__ self._execute_child(args, executable, preexec_fn, close_fds, File "C:\ProgramData\Anaconda3\lib\subprocess.py", line 1420, in _execute_child hp, ht, pid, tid = _winapi.CreateProcess(executable, args, FileNotFoundError: [WinError 2] The system cannot find the file specified pysam: htslib configure options: None [end of output] note: This error originates from a subprocess, and is likely not a problem with pip. error: metadata-generation-failed Encountered error while generating package metadata. See above for output. note: This is an issue with the package mentioned above, not pip. hint: See above for details. I also restarted my laptop, uninstalled and reinstalled Python and Anaconda. I am using Windows, and working in VS through Anaconda as an administrator.
PyMesh problems with Setup on Windows10 and Error using Docker Version
I want to install PyMesh on a Windows 10 PC, if possible it should be installed in the side-packages of an interpreter delivered with the IDE we use. I tried the way to run the setup discribed here https://pymesh.readthedocs.io/en/latest/installation.html so the part : git clone https://github.com/PyMesh/PyMesh.git cd PyMesh git submodule update --init worked without any problems. I am not sure on windows if I now just can write set PYMESH_PATH = path and if i can use the path "...\PyMesh\PyMesh" here? so i left out this part I installed numpy and scipy (allready installed) and nose because it is mentioned in the requirements.txt. So my numpy scipy and nose versions are numpy 1.19.1 scipy 1.6.0 nose 1.3.7 (same as requirenments) and just run the setup.py with admin rights python .\setup.py install which also seemed to work but i got an error trying python -c "import pymesh; pymesh.test()" from the PyMesh folder saying ModuleNotFoundError: No module named 'PyMesh' or if i go up one Folder doing the same saying AttributeError: module 'PyMesh' has no attribute 'triangle' I found this link ImportError: No module named PyMesh but i just dont know what i should type in there I tried to install via pip by using pip install pymesh but pip Installer gives me a different library. So i tried in the docker version and in docker i tried the pymesh.load_mesh method with an stl File but got SyntaxError: (unicode error) 'unicodeescape' codec can't decode bytes in position 2-3: truncated \UXXXXXXXX escape I dont know if this is just the stl format (expecting binary getting ascii or vice versa) The stl file itself can be opened so shouldnt be corrupted. So is there a different way to install pymesh? A wheel would be great. Is it possible to install pymesh to the side-packages of a given Interpreter? Did someone else allready had the same error in Docker and knows the issue thank you for your help
installation jupyterlab-sql on jupyterlab doesn't work
I followed the doc to install jupyterlab-sql but I don't get the SQL launcher in jupyterlab. jupyter labextension list returns JupyterLab v2.1.0 Known labextensions: app dir: c:\users\loicm\appdata\local\continuum\anaconda3\share\jupyter\lab #jupyterlab/toc v0.6.0 enabled X jupyterlab-sql v0.3.3 enabled X The following extension are outdated: #jupyterlab/toc jupyterlab-sql Consider running "jupyter labextension update --all" to check for updates. and jupyter labextension update --all returns An error occured. AttributeError: 'list' object has no attribute 'items' What can I do to get the SQL launcher to work in jupyterlab? Yours sincerely Loïc
Same problem occurs after I updated jupyterlab to 2.x If you check the github page of these extensions, you'll find they only work on jupyterlab 1.x, 2.x is not supported maybe because it was just released.
Using pip 10.0.1 to install modules
lately using 9.0.1, I have been using Project Interpreter to import modules for my files. I opened up a new project in PyCharm today to try and test 10.0.1. Using the Pip version of 10.0.1, I couldn't install packages into my file. The command output was : Traceback (most recent call last): File "C:\Program Files\JetBrains\PyCharm Community Edition 2017.3.3\helpers\packaging_tool.py", line 192, in main retcode = do_install(pkgs) File "C:\Program Files\JetBrains\PyCharm Community Edition 2017.3.3\helpers\packaging_tool.py", line 109, in do_install return pip.main(['install'] + pkgs) AttributeError: module 'pip' has no attribute 'main' I googled this and it said that installing modules through pip was now unsupported, especially for pip._internal.main After looking at this site : https://pip.pypa.io/en/latest/user_guide/#using-pip-from-your-program for a while, it says to use : subprocess.check_call([sys.executable, '-m', 'pip', 'install', 'my_package']) I tried executing it and command prompt said that subprocess.check_call is not an internal or external file. i also tried executing the commands through Command Prompt and downgrading my pip to 9.0.1 but none of this worked. When I changed Pip to 9.0.1 in Command Prompt, it had no effect on PyCharm. Can anyone help with trying to import modules into PyCharm because I am currently trying to make a webcrawler using modules beautifulsoup4 and it is not letting me import it.
OSError: No such file or directory: '[virtual environment]/..local/lib/python2.7/site-packages/[package-name]-0.1-py2.7.egg'
I am creating an PYPI application(to install using pip). I built it using command "python setup.py build" and installed in local machine(inside virtual environment. using [ubuntu 12.4]). whenever I try to UN-install using "pip uninstall " it gives the following error. Message displayed while installing it Copying fantain_DBC-0.1-py2.7.egg to /home/kavin/.virtualenvs/pavan_pkg/lib/python2.7/site-packages Adding fantain-DBC 0.1 to easy-install.pth file Installed /home/kavin/.virtualenvs/pavan_pkg/lib/python2.7/site-packages/fantain_DBC-0.1-py2.7.egg Processing dependencies for fantain-DBC==0.1 Finished processing dependencies for fantain-DBC==0.1 Blockquote Error message while uninstalling OSError: [Errno 2] No such file or directory: '/home/kavin/.virtualenvs/pavan_pkg/local/lib/python2.7/site-packages/fantain_DBC-0.1-py2.7.egg'