Y
Y
Yura Milevsky2021-03-21 19:48:39
Python
Yura Milevsky, 2021-03-21 19:48:39

How to install python-levenshtein?

It gives me this error:

Collecting python-Levenshtein
Using cached python-Levenshtein-0.12.2.tar.gz (50 kB)
Requirement already satisfied: setuptools in f:\programming\python3.9.2\lib\site-packages (from python-Levenshtein) (54.1. 2)
Using legacy 'setup.py install' for python-Levenshtein, since package 'wheel' is not installed.
Installing collected packages: python-Levenshtein
Running setup.py install for python-Levenshtein ... error
ERROR: Command errored out with exit status 1:
command: 'f:\programming\python3.9.2\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\1rock\\AppData\\Local\\Temp\\pip-install-v7rixp21\\python-levenshtein_296ba8f7b4fa4d5fbe7b7a9bc0014935\\setup.py'"'" '; __file__='"'"'C:\\Users\\1rock\\AppData\\Local\\Temp\\pip-install-v7rixp21\\python-levenshtein_296ba8f7b4fa4d5fbe7b7a9bc0014935\\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:
cwd: C:\Users\1rock\AppData\Local\Temp\pip-install-v7rixp21\python-levenshtein_296ba8f7b4fa4d5fbe7b7a9bc0014935\
Complete output (27 lines):
running install
running build
running build_py
creating build
creating build\lib.win-amd64-3.9
creating build\lib.win-amd64-3.9\Levenshtein
copying Levenshtein\StringMatcher.py -> build\lib.win-amd64-3.9\Levenshtein
copying Levenshtein\__init__.py -> build\lib.win-amd64-3.9\Levenshtein
running egg_info
writing python_Levenshtein.egg-info\PKG-INFO
writing dependency_links to python_Levenshtein.egg-info\dependency_links.txt
writing entry points to python_Levenshtein.egg-info\entry_points.txt
writing namespace_packages to python_Levenshtein.egg-info\namespace_packages.txt
writing requirements to python_Levenshtein.egg-info\
requires.txt .txt
reading manifest file 'python_Levenshtein.egg-info\SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no previously-included files matching '*pyc' found anywhere in distribution
warning: no previously-included files matching '* so' found anywhere in distribution
warning: no previously-included files matching '.project' found anywhere in distribution
warning: no previously-included files matching '.pydevproject' found anywhere in distribution
writing manifest file 'python_Levenshtein.egg-info\SOURCES.txt'
copying Levenshtein\_levenshtein.c -> build\lib.win-amd64-3.9\Levenshtein
copying Levenshtein\_levenshtein.h -> build\lib.win-amd64-3.9\Levenshtein
running build_ext
building 'Levenshtein._levenshtein' extension
error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools": https://visualstudio.microsoft.com/visual-cpp-buil...
---------------------- ------------------
ERROR: Command errored out with exit status 1: 'f:\programming\python3.9.2\python.exe' -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\1rock\\AppData\\Local\\Temp\\pip-install-v7rixp21\\python-levenshtein_296ba8f7b4fa4d5fbe7b7a9bc0014935\\setup.py'"'" '; __file__='"'"'C:\\Users\\1rock\\AppData\\Local\\Temp\\pip-install-v7rixp21\\python-levenshtein_296ba8f7b4fa4d5fbe7b7a9bc0014935\\setup.py'"'"';f=getattr (tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'" '\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'

What to do?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
S
Sergey Karbivnichy, 2021-03-21
@Hackerman1

error: Microsoft Visual C++ 14.0 or greater is required. Get it with "Microsoft C++ Build Tools":

It even has a download link.

D
DmlD, 2021-11-12
@DmlD

Hello, I can help.
To start:

  1. You need to install Microsoft C++ Build Tools And select C++ build tools there. Install what is indicated in advance
  2. Install Cmake . Choose .msi
  3. Then enter: pip install python-levenshtein.

Now you should be able to. Sorry if the answer was late...

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question