Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
272 views
in Technique[技术] by (71.8m points)

python - Not able to install Jupyterlab extensions on GCP AI Platform Notebooks

I have started to experience an issue with installing extensions for Jupyterlab that I have not experienced in the past. I am not able to build after installing new extensions for Jupyterlab.

I am running Jupyterlab with GCP AI Platform Notebooks. I am using the standard Python 3 environment on Debian 10. I have tried to run on different types of machines.

I am receiving a status 500 error. Here is the log from when I run jupyter lab build:

[LabBuildApp] WARNING | Config option `kernel_spec_manager_class` not recognized by `LabBuildApp`.
[LabBuildApp] JupyterLab 1.2.16
[LabBuildApp] Building in /opt/conda/share/jupyter/lab
[LabBuildApp] Building jupyterlab assets (build:prod:minimize)
An error occured.
PermissionError: [Errno 1] Operation not permitted: '/opt/conda/share/jupyter/lab/staging/index.js'
See the log file for details:  /tmp/jupyterlab-debug-pnbu3naq.log

Here is the log file with details:

[LabBuildApp] Building in /opt/conda/share/jupyter/lab
[LabBuildApp] Yarn configuration loaded.
[LabBuildApp] Node v15.3.0

[LabBuildApp] Building jupyterlab assets (build:prod:minimize)
[LabBuildApp] Traceback (most recent call last):

[LabBuildApp]   File "/opt/conda/lib/python3.7/site-packages/jupyterlab/debuglog.py", line 47, in debug_logging
    yield

[LabBuildApp]   File "/opt/conda/lib/python3.7/site-packages/jupyterlab/labapp.py", line 98, in start
    command=command, app_options=app_options)

[LabBuildApp]   File "/opt/conda/lib/python3.7/site-packages/jupyterlab/commands.py", line 459, in build
    command=command, clean_staging=clean_staging)

[LabBuildApp]   File "/opt/conda/lib/python3.7/site-packages/jupyterlab/commands.py", line 650, in build
    clean=clean_staging

[LabBuildApp]   File "/opt/conda/lib/python3.7/site-packages/jupyterlab/commands.py", line 1103, in _populate_staging
    shutil.copy(pjoin(HERE, 'staging', fname), target)

[LabBuildApp]   File "/opt/conda/lib/python3.7/shutil.py", line 249, in copy
    copymode(src, dst, follow_symlinks=follow_symlinks)

[LabBuildApp]   File "/opt/conda/lib/python3.7/shutil.py", line 144, in copymode
    chmod_func(dst, stat.S_IMODE(st.st_mode))

[LabBuildApp] PermissionError: [Errno 1] Operation not permitted: '/opt/conda/share/jupyter/lab/staging/index.js'

[LabBuildApp] Exiting application: JupyterLab

Since I have been able to install the same extensions for Jupyterlab in the past on other VM instances I would expect it has something to do with the version of Jupyterlab that is installed. I would, however, expect that Google would install the latest version of Jupyterlab.

The error log does seem to indicate that it is a permission error, which I don't understand as I am running the jupyter lab build at base. The only setting I have changed after creating the instance is to enable extensions.

question from:https://stackoverflow.com/questions/65950610/not-able-to-install-jupyterlab-extensions-on-gcp-ai-platform-notebooks

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)
Waitting for answers

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

1.4m articles

1.4m replys

5 comments

57.0k users

...