ilesinge / shabda

Shabda is a semantic audio samples curator for livecoding software such as Estuary or Tidal Cycles
https://shabda.ndre.gr/
MIT License
17 stars 0 forks source link

pipenv install fails #8

Closed hellocatfood closed 1 year ago

hellocatfood commented 1 year ago

Trying to compile 29faf7a and install dependencies with pipenv install and it gives me the following error, even on a clean installation:

/home/hellocatfood/.local/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: 1.16.0-unknown is an invalid version and will not be supported in a future release
  warnings.warn(
/home/hellocatfood/.local/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: 2.22.1ubuntu1 is an invalid version and will not be supported in a future release
  warnings.warn(
/home/hellocatfood/.local/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: 0.1.43ubuntu1 is an invalid version and will not be supported in a future release
  warnings.warn(
/home/hellocatfood/.local/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: 1.1build1 is an invalid version and will not be supported in a future release
  warnings.warn(
Creating a virtualenv for this project...
Pipfile: /home/hellocatfood/Desktop/shabda/Pipfile
Using /usr/bin/python3 (3.10.6) to create virtualenv...
⠼ Creating virtual environment...created virtual environment CPython3.10.6.final.0-64 in 130ms
  creator CPython3Posix(dest=/home/hellocatfood/.local/share/virtualenvs/shabda-aQTE5Ffy, clear=False, no_vcs_ignore=False, global=False)
  seeder FromAppData(download=False, pip=bundle, setuptools=bundle, wheel=bundle, via=copy, app_data_dir=/home/hellocatfood/.local/share/virtualenv)
    added seed packages: pip==22.2.2, setuptools==65.3.0, wheel==0.37.1
  activators BashActivator,CShellActivator,FishActivator,NushellActivator,PowerShellActivator,PythonActivator

✔ Successfully created virtual environment! 
Traceback (most recent call last):
  File "/home/hellocatfood/.local/bin/pipenv", line 8, in <module>
    sys.exit(cli())
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 1128, in __call__
    return self.main(*args, **kwargs)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/cli/options.py", line 56, in main
    return super().main(*args, **kwargs, windows_expand_args=False)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 1053, in main
    rv = self.invoke(ctx)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 1659, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 1395, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 754, in invoke
    return __callback(*args, **kwargs)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/vendor/click/decorators.py", line 84, in new_func
    return ctx.invoke(f, obj, *args, **kwargs)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 754, in invoke
    return __callback(*args, **kwargs)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/cli/command.py", line 234, in install
    do_install(
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/core.py", line 1973, in do_install
    ensure_project(
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/core.py", line 553, in ensure_project
    ensure_virtualenv(
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/core.py", line 486, in ensure_virtualenv
    do_create_virtualenv(
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/core.py", line 1019, in do_create_virtualenv
    project._environment = Environment(
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/environment.py", line 72, in __init__
    self._base_paths = self.get_paths()
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/environment.py", line 394, in get_paths
    c = subprocess_run(command)
  File "/home/hellocatfood/.local/lib/python3.10/site-packages/pipenv/utils/processes.py", line 75, in subprocess_run
    return subprocess.run(
  File "/usr/lib/python3.10/subprocess.py", line 501, in run
    with Popen(*popenargs, **kwargs) as process:
  File "/usr/lib/python3.10/subprocess.py", line 969, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/lib/python3.10/subprocess.py", line 1845, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: '/home/hellocatfood/.local/share/virtualenvs/shabda-aQTE5Ffy/bin/python'

Using Ubuntu 22.04

ilesinge commented 1 year ago

Oops, this is unfortunate. I'll look into that. For info the text to speech feature is not available yet in the command line interface, and still hidden in the web interface 🤗

ilesinge commented 1 year ago

Hello @hellocatfood , I had no luck reproducing the issue. Did you install Python with Homebrew ? Apparently, it has been encountered by other pipenv users. If so, you may find some tips here: https://github.com/pypa/pipenv/issues/4466 or here: https://stackoverflow.com/questions/64388435/using-pipenv-install-on-a-mac-fails-with-no-such-file-or-directory-errors

hellocatfood commented 1 year ago

Ah I forgot to mention that I'm running this on Ubuntu 22.04.

Also I think I found the issue. In previous versions I could run python shabda_cli.py sound:2 but in recent versions I have to add pipenv run at the beginning which I didn't realise.

If I run without pipenv run then I get a lot of errors about modules being missing.

ilesinge commented 1 year ago

Could you try to simply: pip install shabda ?

Then the shabda command should be available wherever you are.

Samples will be downloaded in a samples directory under your current directory, unless you create a shabda config file in $HOME/.shabda/config.ini with the following data:

[shabda]

samples_path=/path/to/wherever/you/want/your/samples/
hellocatfood commented 1 year ago

Ah great to see that shabda is now on pip! I tried running shabda drum:5 but got this error:

Traceback (most recent call last):
  File "/home/hellocatfood/.local/bin/shabda", line 5, in <module>
    from shabda_cli import cli
ModuleNotFoundError: No module named 'shabda_cli'
ilesinge commented 1 year ago

I guess it is now fixed! Could you try upgrading shabda and retry? pip install --upgrade shabda

hellocatfood commented 1 year ago

All working now!