我在Windows命令提示符下键入以下内容:pip install jupyterlab
我收到以下错误:
ERROR: Command errored out with exit status 1: command: 'c:\users\admin\appdata\local\programs\python\python38-32\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-0mx8si2m\\pywinpty\\setup.py'"'"'; __file__='"'"'C:\\Users\\Admin\\AppData\\Local\\Temp\\pip-install-0mx8si2m\\pywinpty\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\Admin\AppData\Local\Temp\pip-install-0mx8si2m\pywinpty\pip-egg-info' cwd: C:\Users\Admin\AppData\Local\Temp\pip-install-0mx8si2m\pywinpty\ Complete output (166 lines): Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Plex\Scanners.py because it changed. Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Plex\Actions.py because it changed. Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\Scanning.py because it changed. Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\Visitor.py because it changed. Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\FlowControl.py because it changed. Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Runtime\refnanny.pyx because it changed. Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\FusedNode.py because it changed. Compiling C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Tempita\_tempita.py because it changed. [1/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\FlowControl.py [2/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\FusedNode.py [3/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\Scanning.py [4/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Compiler\Visitor.py [5/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Plex\Actions.py [6/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Plex\Scanners.py [7/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Runtime\refnanny.pyx [8/8] Cythonizing C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Tempita\_tempita.py Unable to find pgen, not compiling formal grammar. warning: no files found matching 'Doc\*' warning: no files found matching '*.pyx' under directory 'Cython\Debugger\Tests' warning: no files found matching '*.pxd' under directory 'Cython\Debugger\Tests' warning: no files found matching '*.pxd' under directory 'Cython\Utility' warning: no files found matching 'pyximport\README' Scanners.c Creating library build\temp.win32-3.8\Release\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Plex\Scanners.cp38-win32.lib and object build\temp.win32-3.8\Release\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\Cython\Plex\Scanners.cp38-win32.exp Generating code Finished generating code LINK : fatal error LNK1158: cannot run 'rc.exe' Traceback (most recent call last): File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 534, in link self.spawn([self.linker] + ld_args) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 557, in spawn return super().spawn(cmd) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\ccompiler.py", line 910, in spawn spawn(cmd, dry_run=self.dry_run) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\spawn.py", line 38, in spawn _spawn_nt(cmd, search_path, dry_run=dry_run) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\spawn.py", line 80, in _spawn_nt raise DistutilsExecError( distutils.errors.DistutilsExecError: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\link.exe' failed with exit status 1158 During handling of the above exception, another exception occurred: Traceback (most recent call last): File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\core.py", line 148, in setup dist.run_commands() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\dist.py", line 966, in run_commands self.run_command(cmd) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\dist.py", line 985, in run_command cmd_obj.run() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\bdist_egg.py", line 172, in run cmd = self.call_command('install_lib', warn_dir=0) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\bdist_egg.py", line 158, in call_command self.run_command(cmdname) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\cmd.py", line 313, in run_command self.distribution.run_command(command) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\dist.py", line 985, in run_command cmd_obj.run() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\install_lib.py", line 11, in run self.build() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\command\install_lib.py", line 107, in build self.run_command('build_ext') File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\cmd.py", line 313, in run_command self.distribution.run_command(command) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\dist.py", line 985, in run_command cmd_obj.run() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\build_ext.py", line 84, in run _build_ext.run(self) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\command\build_ext.py", line 340, in run self.build_extensions() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\command\build_ext.py", line 449, in build_extensions self._build_extensions_serial() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\command\build_ext.py", line 474, in _build_extensions_serial self.build_extension(ext) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\build_ext.py", line 205, in build_extension _build_ext.build_extension(self, ext) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\command\build_ext.py", line 550, in build_extension self.compiler.link_shared_object( File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\ccompiler.py", line 713, in link_shared_object self.link(CCompiler.SHARED_OBJECT, objects, File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\_msvccompiler.py", line 537, in link raise LinkError(msg) distutils.errors.LinkError: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\link.exe' failed with exit status 1158 During handling of the above exception, another exception occurred: Traceback (most recent call last): File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules yield saved File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context yield File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup _execfile(setup_script, ns) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile exec(code, globals, locals) File "C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\setup.py", line 228, in File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 145, in setup return distutils.core.setup(**attrs) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\core.py", line 163, in setup raise SystemExit("error: " + str(msg)) SystemExit: error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\link.exe' failed with exit status 1158 During handling of the above exception, another exception occurred: Traceback (most recent call last): File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 1144, in run_setup run_setup(setup_script, args) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 253, in run_setup raise File "c:\users\admin\appdata\local\programs\python\python38-32\lib\contextlib.py", line 131, in __exit__ self.gen.throw(type, value, traceback) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context yield File "c:\users\admin\appdata\local\programs\python\python38-32\lib\contextlib.py", line 131, in __exit__ self.gen.throw(type, value, traceback) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 166, in save_modules saved_exc.resume() File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 141, in resume six.reraise(type, exc, self._tb) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\_vendor\six.py", line 685, in reraise raise value.with_traceback(tb) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 154, in save_modules yield saved File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 195, in setup_context yield File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 250, in run_setup _execfile(setup_script, ns) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\sandbox.py", line 45, in _execfile exec(code, globals, locals) File "C:\Users\Admin\AppData\Local\Temp\easy_install-rvu4jwr1\Cython-0.29.14\setup.py", line 228, in File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 145, in setup return distutils.core.setup(**attrs) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\distutils\core.py", line 163, in setup raise SystemExit("error: " + str(msg)) SystemExit: error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\link.exe' failed with exit status 1158 During handling of the above exception, another exception occurred: Traceback (most recent call last): File "", line 1, in File "C:\Users\Admin\AppData\Local\Temp\pip-install-0mx8si2m\pywinpty\setup.py", line 68, in setup( File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 144, in setup _install_setup_requires(attrs) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\__init__.py", line 139, in _install_setup_requires dist.fetch_build_eggs(dist.setup_requires) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\dist.py", line 716, in fetch_build_eggs resolved_dists = pkg_resources.working_set.resolve( File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 780, in resolve dist = best[req.key] = env.best_match( File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 1065, in best_match return self.obtain(req, installer) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 1077, in obtain return installer(requirement) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\dist.py", line 786, in fetch_build_egg return cmd.easy_install(req) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 679, in easy_install return self.install_item(spec, dist.location, tmpdir, deps) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 705, in install_item dists = self.install_eggs(spec, download, tmpdir) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 890, in install_eggs return self.build_and_install(setup_script, setup_base) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 1158, in build_and_install self.run_setup(setup_script, setup_base, args) File "c:\users\admin\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\command\easy_install.py", line 1146, in run_setup raise DistutilsError("Setup script exited with %s" % (v.args[0],)) distutils.errors.DistutilsError: Setup script exited with error: command 'C:\\Program Files (x86)\\Microsoft Visual Studio 14.0\\VC\\BIN\\link.exe' failed with exit status 1158 ---------------------------------------- ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
答案 0 :(得分:0)
只需按照此在 Windows 中安装 jupyter :-
1nd - 转到文件管理器并找到 python 文件夹(例如:-python、python37、python39 等...)可能是它位于 (C:\Python39) 或 (C:\Users\prade\AppData\Local\Programs\python39) .
2rd - 在 python 文件夹中打开 Scripts 文件夹(例如:- C:.....\python39\Scripts)并复制此路径。
3rd - '以管理员身份运行 cmd' 并使用 cd 越过上述路径(例如:- cd C:.....\python39\Scripts)>
4th - 现在只需使用 jupyter install 命令(例如:-
<块引用>pip 安装 jupyterlab
)