-
Notifications
You must be signed in to change notification settings - Fork 551
How to install dedupe, [TUTORIAL] on Windows 7
https://github.com/dedupeio/dedupe/issues/712
Here are some steps I took in successfully installing dedupe windows 7, without errors:
1.a.) Install python 3.6 64 bit. https://www.python.org/downloads/release/python-360/
1.b.) First, upgrade pip, to avoid yellow warnings or SSL certificate errors. If you don't update pip, you can use install commands with trusted flags: "pip install --trusted-host pypi.org --trusted-host files.pythonhosted.org <Put your-package-name here, eg 'numpy'>".
2.a.) Install numpy. Cmd: "pip install numpy".
2.b.) Check if numpy installed. Cmd: "pip show numpy".
3.a.) Install setuptools 40.6.2. Cmd: "python setuptools_dir/setup.py install". https://pypi.org/project/setuptools/
3.b.) Check if setuptools installed. Cmd: "pip show setuptools ".
4.a.) Install mingw32, download "mingw-get-setup.exe". https://osdn.net/projects/mingw/releases/
4.b.) Ensure that C:\MinGW\bin (or wherever MinGW is installed) contains gcc.exe. In cmd, do a test "gcc -dumpversion", and if that succeeds you're great. Otherwise, you'll need to go to C:\MinGW\bin, and click mingw-get, then mark "...gcc-bin" for installation, then apply changes.
4.c.) Alternatively instead of 4.a to 4.b above, you could create a folder called MinGW in your C or whatever drive, then copy the contents of gcc-core package from the same official website to that folder. It performs the same steps from 4.a. to 4.b.
5.) Add the 2 lines below to a new file called distutils.cfg to python/Lib/distils python installation. This will prevent "vcvarsall.bat" error or "Visual C++ requirement" error. (Assuming the "distutils.cfg" file did not exist)
line1: [build]
line2: compiler=mingw32.exe
(Note: The ".exe" portion is very important here, and many other guidelines tend to leave this out! This will also help to prevent a NoneType Error.)
6.) Add mingw32 to environement path, or set path as typically "C:\MinGW\bin;" in cmd before installing dedupe by cmd. This will prevent critical "NoneType Error" (aka red errors related to certificate failure) at "dedupe" installation. Ensure that this is the location seen in item 4.c.
7.) Add vcruntime140.dll to Python/libs folder. This will help fix the Unknown MS Compiler Version Error.
8.) Add patch to Python/Lib/disutils/cygwinccompiler.py. Change the get_msvcr() method, to the method seen in this file organized by myself to be python tab safe, or otherwise apply the change from the specific bug fix python page. (Note that the official page's code will yield an error if you copy it to your cygwinccompiler.py get_msvcr method, even after you remove the irrelevant plus signs, and ensure all things align. You'll need to delete the tabs, and replace them with the corresponding number of spaces.)
9.a.) Install dedupe. Cmd: "python <location of dedupe-github-master-folder>/setup.py install" (Note that pip install dedupe yields an error. Use the python command to install dedupe directly from dedupe repository)
9.b.) Check if dedupe installed. Cmd: "pip show dedupe".