pndurette / gTTS

Python library and CLI tool to interface with Google Translate's text-to-speech API
http://gtts.readthedocs.org/
MIT License
2.32k stars 361 forks source link

Fail to install using pip install gTTS #158

Closed terian-itinera closed 5 years ago

terian-itinera commented 5 years ago

When run: pip install gTTS I'm getting the following error:

`usuario@acpNotifica:~$ pip3 install gTTS Collecting gTTS Downloading https://files.pythonhosted.org/packages/77/1e/8e2990a0af8811129869a985abd9a31958125cb2098d93f18ab23f4a59c8/gTTS-2.0.2.tar.gz Running setup.py (path:/tmp/pip-build-1fg_sg05/gTTS/setup.py) egg_info for package gTTS produced metadata for project name unknown. Fix your #egg=gTTS fragments. Building wheels for collected packages: unknown, unknown Running setup.py bdist_wheel for unknown ... done Stored in directory: /home/usuario/.cache/pip/wheels/88/47/6e/15f4ba2921f49ca5aed607f8310e063083edabc4a1b1ea42f9 Running setup.py bdist_wheel for unknown ... error Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-1fg_sg05/unknown/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" bdist_wheel -d /tmp/tmpyrqfgp1_pip-wheel- --python-tag cp35: Traceback (most recent call last): File "", line 1, in File "/usr/lib/python3.5/tokenize.py", line 454, in open buffer = _builtin_open(filename, 'rb') FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-build-1fg_sg05/unknown/setup.py'


Failed building wheel for unknown Running setup.py clean for unknown Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;file='/tmp/pip-build-1fg_sg05/unknown/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" clean --all: Traceback (most recent call last): File "", line 1, in File "/usr/lib/python3.5/tokenize.py", line 454, in open buffer = _builtin_open(filename, 'rb') FileNotFoundError: [Errno 2] No such file or directory: '/tmp/pip-build-1fg_sg05/unknown/setup.py'


Failed cleaning build dir for unknown Successfully built unknown Failed to build unknown Installing collected packages: unknown Successfully installed unknown You are using pip version 8.1.1, however version 18.1 is available. You should consider upgrading via the 'pip install --upgrade pip' command. `

terian-itinera commented 5 years ago

Is detected as UNKNOWN!!!

terian-itinera commented 5 years ago

Using Pytho2 I¡ve goy almost the same error:

usuario@acpNotifica:~$ pip install --user gTTS Collecting gTTS Installing collected packages: gTTS Exception: Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/pip/_internal/cli/base_command.py", line 143, in main status = self.run(options, args) File "/usr/local/lib/python2.7/dist-packages/pip/_internal/commands/install.py", line 366, in run use_user_site=options.use_user_site, File "/usr/local/lib/python2.7/dist-packages/pip/_internal/req/__init__.py", line 49, in install_given_reqs **kwargs File "/usr/local/lib/python2.7/dist-packages/pip/_internal/req/req_install.py", line 760, in install use_user_site=use_user_site, pycompile=pycompile, File "/usr/local/lib/python2.7/dist-packages/pip/_internal/req/req_install.py", line 382, in move_wheel_files warn_script_location=warn_script_location, File "/usr/local/lib/python2.7/dist-packages/pip/_internal/wheel.py", line 326, in move_wheel_files assert info_dir, "%s .dist-info directory not found" % req AssertionError: gTTS .dist-info directory not found

terian-itinera commented 5 years ago

More info... ` usuario@acpNotifica:~$ pip list Package Version


codebug-tether 0.9.1 distribute 0.7.3 Markdown 3.0.1 pip 18.1 pyttsx 1.1 RTIMULib 7.2.1 setuptools 40.6.2 six 1.12.0 UNKNOWN 2.0.2 wheel 0.29.0 `

terian-itinera commented 5 years ago

Any idea how to fix it?

mdeghdache commented 5 years ago

Hello, i have the same problem as "terian-itinera" i cannot upgrade gTTS from pip3 "AssertionError: gTTS .dist-info directory not found"

ipeakermit commented 5 years ago

Same here using pip2

ipeakermit commented 5 years ago

For pip2 try the following workaround after failed install (Ubuntu 16.04):

cd ~/.local/lib/python2.7/site-packages/ mv UNKNOWN-2.0.2.dist-info/ gTTS-2.0.2.dist-info/ pip install --user --force-reinstall --ignore-installed --no-binary :all: gTTS

terian-itinera commented 5 years ago

Thanks, the solution made by ipeakermint did the work.

Now my app is talking again!!!

bghanchi commented 5 years ago

For pip2 try the following workaround after failed install (Ubuntu 16.04):

cd ~/.local/lib/python2.7/site-packages/ mv UNKNOWN-2.0.2.dist-info/ gTTS-2.0.2.dist-info/ pip install --user --force-reinstall --ignore-installed --no-binary :all: gTTS

Thanks, ipeakermit your solution work

ArgiesDario commented 4 years ago

For pip2 try the following workaround after failed install (Ubuntu 16.04):

cd ~/.local/lib/python2.7/site-packages/ mv UNKNOWN-2.0.2.dist-info/ gTTS-2.0.2.dist-info/ pip install --user --force-reinstall --ignore-installed --no-binary :all: gTTS

life saver, for me it worked only forcing reinstall:

pip install --user --force-reinstall --ignore-installed --no-binary :all: your_package

Lonol-last commented 4 years ago

thank you