Проблемы при установке edx-dl пакета с зернышком

Я хотел увеличить объем загрузки некоторая лекция с YouTube и edX, таким образом, я смотрел на проект здесь:

https://github.com/coursera-dl/edx-dl

Я использую Python 3.4.3, как предложено в вышеупомянутой ссылке

$ python
Python 3.4.3 (default, Oct 14 2015, 20:28:29) 
[GCC 4.8.4] on linux
Type "help", "copyright", "credits" or "license" for more information.

Теперь я попробовал следующие команды:

  1. pip install youtube-dl

Результат был следующие:

sparsh@sparsh-Inspiron-3558:~$ pip install youtube-dl
Downloading/unpacking youtube-dl
  Downloading youtube_dl-2016.7.24-py2.py3-none-any.whl (1.4MB): 1.4MB downloaded
Installing collected packages: youtube-dl
Cleaning up...
Exception:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 283, in run
    requirement_set.install(install_options, global_options, root=options.root_path)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1436, in install
    requirement.install(install_options, global_options, *args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 672, in install
    self.move_wheel_files(self.source_dir, root=root)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 902, in move_wheel_files
    pycompile=self.pycompile,
  File "/usr/lib/python2.7/dist-packages/pip/wheel.py", line 206, in move_wheel_files
    clobber(source, lib_dir, True)
  File "/usr/lib/python2.7/dist-packages/pip/wheel.py", line 193, in clobber
    os.makedirs(destsubdir)
  File "/usr/lib/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
OSError: [Errno 13] Permission denied: '/usr/local/lib/python2.7/dist-packages/youtube_dl-2016.7.24.dist-info'

Storing debug log for failure in /home/sparsh/.pip/pip.log
sparsh@sparsh-Inspiron-3558:~$ pip install --upgrade youtube-dl
Downloading/unpacking youtube-dl
  Downloading youtube_dl-2016.7.24-py2.py3-none-any.whl (1.4MB): 1.4MB downloaded
Installing collected packages: youtube-dl
Cleaning up...
Exception:
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/pip/basecommand.py", line 122, in main
    status = self.run(options, args)
  File "/usr/lib/python2.7/dist-packages/pip/commands/install.py", line 283, in run
    requirement_set.install(install_options, global_options, root=options.root_path)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 1436, in install
    requirement.install(install_options, global_options, *args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 672, in install
    self.move_wheel_files(self.source_dir, root=root)
  File "/usr/lib/python2.7/dist-packages/pip/req.py", line 902, in move_wheel_files
    pycompile=self.pycompile,
  File "/usr/lib/python2.7/dist-packages/pip/wheel.py", line 206, in move_wheel_files
    clobber(source, lib_dir, True)
  File "/usr/lib/python2.7/dist-packages/pip/wheel.py", line 193, in clobber
    os.makedirs(destsubdir)
  File "/usr/lib/python2.7/os.py", line 157, in makedirs
    mkdir(name, mode)
OSError: [Errno 13] Permission denied: '/usr/local/lib/python2.7/dist-packages/youtube_dl-2016.7.24.dist-info'

Storing debug log for failure in /home/sparsh/.pip/pip.log
  1. Когда я попробовал команду: pip install edx-dl

Результат был следующие:

    sparsh@sparsh-Inspiron-3558:~$ pip install edx-dl
Downloading/unpacking edx-dl
  Downloading edx-dl-0.1.2.tar.gz
  Running setup.py (path:/tmp/pip_build_sparsh/edx-dl/setup.py) egg_info for package edx-dl

Downloading/unpacking beautifulsoup4>=4.1.3 (from edx-dl)
  Downloading beautifulsoup4-4.5.0-py2-none-any.whl (83kB): 83kB downloaded
Downloading/unpacking html5lib>=1.0b2 (from edx-dl)
  Downloading html5lib-1.0b10.tar.gz (245kB): 245kB downloaded
  Running setup.py (path:/tmp/pip_build_sparsh/html5lib/setup.py) egg_info for package html5lib
    html5lib requires setuptools version 18.5 or above; please upgrade before installing (you have 3.3)
    Complete output from command python setup.py egg_info:
    html5lib requires setuptools version 18.5 or above; please upgrade before installing (you have 3.3)

----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /tmp/pip_build_sparsh/html5lib
Storing debug log for failure in /home/sparsh/.pip/pip.log

Версия зернышка

sparsh@sparsh-Inspiron-3558:~$ pip --version
pip 1.5.4 from /usr/lib/python2.7/dist-packages (python 2.7)

Как я могу зафиксировать это? Если существует лучший метод для загрузки лекций edX, оптом совместно используйте.

2
задан 26 July 2016 в 17:59

1 ответ

pip python2 файл. Использовать зернышко с python3: Установка и использование pip3.

sudo apt install python3-pip ( provides /usr/bin/pip3 )

pip3 install youtube-dl
0
ответ дан 2 December 2019 в 10:21

Другие вопросы по тегам:

Похожие вопросы: