YT-Spammer-Purge
YT-Spammer-Purge copied to clipboard
[Bug]: Not installing on Mac
Duplicate Issues
- [X] There are no existing posts relating to my problem
- [ ] There are existing posts relating to my problem, but the solution given, doesn't work for me.
What happened?
after running "pip3 install -r requirements.txt", it errors out on a package called python-Levenshtein. I believe there is a problem with the package itself as I tried to install it separately and it failed. can you fix this.
OS - macOS Monterey 12.1 Laptop - MacBook Air 2017
Release version
v2.16
Steps to reproduce
- download zip
- unzip the .zip file
- open the folder in terminal
- run "pip3 install -r requirements.txt"
Tried out multiple times, error happened every time. I even reinstall python3 so I don't believe it's a problem with pip or python. Just a problem with the package itself (python-Levenshtein) (referenced from the error message)
What platform are you seeing this problem on?
MacOS
Relevant log output
102 warnings generated.
clang -bundle -undefined dynamic_lookup -arch arm64 -arch x86_64 -g -L/usr/local/opt/icu4c/lib set -gx CPPFLAGS -I/usr/local/opt/icu4c/include build/temp.macosx-10.9-universal2-3.10/Levenshtein/_levenshtein.o -o build/lib.macosx-10.9-universal2-3.10/Levenshtein/_levenshtein.cpython-310-darwin.so
clang: error: unknown argument: '-gx'
clang: error: no such file or directory: 'set'
clang: error: no such file or directory: 'CPPFLAGS'
error: command '/usr/bin/clang' failed with exit code 1
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> python-Levenshtein
note: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
Screenshots
No response
that's strange (because it somehow asks to build for arm too see -arch arm64, not sure why )
but possibly installing gcc and compiling from source would help (maybe just running from source https://pypi.org/project/python-Levenshtein/#files python3 setup.py build python3 setup.py install will do the trick if not see below)
from https://github.com/ThioJoe/YT-Spammer-Purge/issues/523 download source code https://pypi.org/project/python-Levenshtein/#files install gcc I guess, install python3-develop (maybe not needed) brew install python3-develop python3 setup.py build python setup.py install (maybe prefix with sudo: sudo python3 setup.py install )
btw it is not common problem, there are mac screenshots successfully running script (after python Levenshtein was added as dependency), so you have to find what is specifically wrong with your setup
run pip3 install python-Levenshtein
non mac user here
op already made issue https://github.com/ztane/python-Levenshtein/issues/81
try remove python-Levenshtein>=0.12.2
with levenshtein
on requirements.txt
and try run the program
levenshtein is fork of python-levenshtein so i assume everything should work as before
if you success create pr to replace the package
see also
https://github.com/ztane/python-Levenshtein/issues/61
I was about to suggest trying to run under Rosetta, but seeing that you are using an Air from 2017, it's probably a Monterey bug.
According to Wikipedia, the latest version is 12.2.1
. I would recommend upgrading to see if that fixes the bug, but seeing that Apple gives vague update descriptions (i.e Recommended bug fixes for most users
), I'm not sure if that will fix the issue.
had same issue on ubuntu:
https://github.com/ThioJoe/YT-Spammer-Purge/pull/720
@Jimbolino i'm on ubuntu 21.10 with python3.9 can install levenstein without problem
and also can you post full error text
e: your current error text little bit different than this one
@rachmadaniHaryono i've created a new issue, because the error message is about the same Levenshtein package, but the solution is probably not :) https://github.com/ThioJoe/YT-Spammer-Purge/issues/721
I believe this should be fixed in the current version, since it does no longer use python-Levenshtein