pywintypes.error:(50,"GetFileSecurity",“不支持该请求.")在网络驱动器上使用Jupyter Notebook时 [英] pywintypes.error: (50, 'GetFileSecurity', 'The request is not supported.') while using Jupyter Notebook on network drive
问题描述
我目前正在尝试在网络驱动器上使用miniconda + jupyter(与pip一起安装)的组合,但是出现以下错误:
I am currently trying to use a combination of miniconda + jupyter (installed with pip) on a network drive and I get the following error:
pywintypes.error:(50,"GetFileSecurity",不支持该请求.")
pywintypes.error: (50, 'GetFileSecurity', 'The request is not supported.')
我目前在公司环境中工作,因此我们在访问权限方面存在一些限制.不幸的是,我只能在网络驱动器上尝试jupyter,更改本地硬盘驱动器需要我没有的管理员权限.
I am currently working in a corporate set-up, so we are working with some limitations regarding access rights. Unfortunately, I can only try jupyter on network drives, changes to the local hard drive requires admin rights which I don't have.
完整的错误输出:
Traceback (most recent call last):
File "c:\programs\miniconda3_64\lib\site-packages\tornado\web.py", line 1699, in _execute
result = await result
File "c:\programs\miniconda3_64\lib\site-packages\tornado\gen.py", line 742, in run
yielded = self.gen.throw(*exc_info) # type: ignore
File "c:\programs\miniconda3_64\lib\site-packages\notebook\services\sessions\handlers.py", line 72, in post
type=mtype))
File "c:\programs\miniconda3_64\lib\site-packages\tornado\gen.py", line 735, in run
value = future.result()
File "c:\programs\miniconda3_64\lib\site-packages\tornado\gen.py", line 742, in run
yielded = self.gen.throw(*exc_info) # type: ignore
File "c:\programs\miniconda3_64\lib\site-packages\notebook\services\sessions\sessionmanager.py", line 88, in create_session
kernel_id = yield self.start_kernel_for_session(session_id, path, name, type, kernel_name)
File "c:\programs\miniconda3_64\lib\site-packages\tornado\gen.py", line 735, in run
value = future.result()
File "c:\programs\miniconda3_64\lib\site-packages\tornado\gen.py", line 742, in run
yielded = self.gen.throw(*exc_info) # type: ignore
File "c:\programs\miniconda3_64\lib\site-packages\notebook\services\sessions\sessionmanager.py", line 101, in start_kernel_for_session
self.kernel_manager.start_kernel(path=kernel_path, kernel_name=kernel_name)
File "c:\programs\miniconda3_64\lib\site-packages\tornado\gen.py", line 735, in run
value = future.result()
File "c:\programs\miniconda3_64\lib\site-packages\tornado\gen.py", line 209, in wrapper
yielded = next(result)
File "c:\programs\miniconda3_64\lib\site-packages\notebook\services\kernels\kernelmanager.py", line 168, in start_kernel
super(MappingKernelManager, self).start_kernel(**kwargs)
File "c:\programs\miniconda3_64\lib\site-packages\jupyter_client\multikernelmanager.py", line 110, in start_kernel
km.start_kernel(**kwargs)
File "c:\programs\miniconda3_64\lib\site-packages\jupyter_client\manager.py", line 240, in start_kernel
self.write_connection_file()
File "c:\programs\miniconda3_64\lib\site-packages\jupyter_client\connect.py", line 547, in write_connection_file
kernel_name=self.kernel_name
File "c:\programs\miniconda3_64\lib\site-packages\jupyter_client\connect.py", line 212, in write_connection_file
with secure_write(fname) as f:
File "c:\programs\miniconda3_64\lib\contextlib.py", line 82, in __enter__
return next(self.gen)
File "c:\programs\miniconda3_64\lib\site-packages\jupyter_client\connect.py", line 100, in secure_write
win32_restrict_file_to_user(fname)
File "c:\programs\miniconda3_64\lib\site-packages\jupyter_client\connect.py", line 61, in win32_restrict_file_to_user
sd = win32security.GetFileSecurity(fname, win32security.DACL_SECURITY_INFORMATION)
ywintypes.error: (50, 'GetFileSecurity', 'The request is not supported.')
您对这种错误有任何想法或经验吗?
Any ideas or experience with this type of error?
推荐答案
对于有此问题的任何人,这似乎是由于更新了jupyter笔记本或任何其他可以更新它的软件包所致.
For anybody having this issue, it seems to be due to updating jupyter notebook, or any other package that can update it.
解决此问题的步骤如下,
The steps to fix the issue are the following,
pip install jupyter
pip install jupyter-client==5.3.1
python -m ipykernel install --user
pip install jupyter
pip install jupyter-client==5.3.1
python -m ipykernel install --user
这篇关于pywintypes.error:(50,"GetFileSecurity",“不支持该请求.")在网络驱动器上使用Jupyter Notebook时的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!