1

I am trying to install Scrappy. I have Python 3.6 installed and am on Windows.

I have tried this:

py -3.5-32 -m pip install Scrappy

However, got the following:

Collecting Scrappy
  Using cached Scrappy-0.3.0.alpha.4.tar.gz
Collecting guessit (from Scrappy)
  Using cached guessit-2.1.2.tar.gz
Collecting tvdb_api (from Scrappy)
  Using cached tvdb_api-1.10.tar.gz
Collecting hachoir-metadata (from Scrappy)
  Using cached hachoir-metadata-1.3.3.tar.gz
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "C:\Users\USER~1.NAME\AppData\Local\Temp\pip-build-1tu2hkos\hachoir-metadata\setup.py", line 65
        except OSError, err:
                      ^
SyntaxError: invalid syntax

----------------------------------------   
Command "python setup.py egg_info" failed with error code 1 in C:\Users\USER~1.NAME\AppData\Local\Temp\pip-build-1tu2hkos\hachoir-metadata\

Which is because of setuptools? So I upgraded it and then tried to install Scrappy but got the same error message.

Anybody know why this is happening?

Update, error when attempting to install Scrapy:

error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": http://landinghub.visualstudio.com/visual-cpp-build-tools

    ----------------------------------------
Command "C:\Users\user.name\AppData\Local\Programs\Python\Python35-32\python.exe

-u -c "import setuptools, tokenize;file='C:\Users\USER~1.NAME\AppData\Local\Temp\pip-build-j6ijek3o\Twisted\setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record C:\Users\USER~1.NAME\AppData\Local\Temp\pip-bmjl_u_2-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\USER~1.NAME\AppData\Local\Temp\pip-build-j6ijek3o\Twisted\

Maverick
  • 789
  • 4
  • 24
  • 45
  • Try using `pip3 --user` – Jack Evans Apr 05 '17 at 16:21
  • I'm relatively new to Python and not heard of `pip3` is this what you mean? - `py -3.5-32 pip3 install Scrappy`? – Maverick Apr 05 '17 at 16:25
  • From Scrapy [docs](https://doc.scrapy.org/en/latest/intro/install.html#windows): Though it’s possible to install Scrapy on Windows using pip, we recommend you to install [Anaconda](https://docs.continuum.io/anaconda/). – vold Apr 05 '17 at 16:31
  • 1
    [scrapy](https://pypi.python.org/pypi/Scrapy/1.3.3) or [scrappy](https://pypi.python.org/pypi/Scrappy/)? scrappy (with 2 p) does not look Python 3 compatible – paul trmbrth Apr 05 '17 at 17:21
  • Thanks @paultrmbrth I was trying to install Scrappy. Tried Scrapy, unfortunately no luck either! – Maverick Apr 05 '17 at 20:58
  • Thanks @vold I think I will try that as nothing else seems to be working. Do you reckon it will install with conda? – Maverick Apr 05 '17 at 20:59
  • Actually, I was thinking you are asking about the Scrapy framework. I can't tell you if Anaconda can help you with Scrappy. You should check their [package list](https://docs.continuum.io/anaconda/pkg-docs). – vold Apr 05 '17 at 21:36
  • 1
    @Maverick, If you're trying to install [Scrappy](https://pypi.python.org/pypi/Scrappy), to _"rename video files based on information scraped from thetvdb.com"_, then I believe you need to use Python 2. Scrappy is not syntax-compatible with Python 3 ([nor does it seem maintained](https://github.com/louist87/Scrappy/commits/master)). – paul trmbrth Apr 06 '17 at 08:29
  • @vold I've installed it with conda, but can't seem to import it... Went back to conda to install it again `All requested packages already installed.` Tried it with pip out of curiosity and all requirements are installed. Restarted my machine, still can't import. Any ideas? – Maverick Apr 06 '17 at 12:51

1 Answers1

14
pip install Scrapy

Scrapy, not scrappy

Scrapy Installation Guide

parik
  • 2,313
  • 12
  • 39
  • 67
  • I tried Scrapy and got, see update for error message. – Maverick Apr 06 '17 at 11:53
  • @Maverick read this answer http://stackoverflow.com/questions/29846087/microsoft-visual-c-14-0-is-required-unable-to-find-vcvarsall-bat – parik Apr 06 '17 at 12:36