enram / vptstools

Python library to transfer and convert vertical profile time series data
https://enram.github.io/vptstools/
MIT License
3 stars 1 forks source link

Cannot install dotenv dependency #49

Closed peterdesmet closed 1 year ago

peterdesmet commented 1 year ago

vph5_to_vpts requires dotenv, but it seems the installation fails:

vph5_to_vpts                                                
Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/3.11/bin/vph5_to_vpts", line 5, in <module>
    from vptstools.bin.vph5_to_vpts import cli
  File "/Library/Frameworks/Python.framework/Versions/3.11/lib/python3.11/site-packages/vptstools/bin/vph5_to_vpts.py", line 10, in <module>
    from dotenv import load_dotenv
pip3 install dotenv
Collecting dotenv
  Using cached dotenv-0.0.5.tar.gz (2.4 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... error
  error: subprocess-exited-with-error

  × pip subprocess to install backend dependencies did not run successfully.
  │ exit code: 1
  ╰─> [29 lines of output]
      Collecting distribute
        Using cached distribute-0.7.3.zip (145 kB)
        Installing build dependencies: started
        Installing build dependencies: finished with status 'done'
        Getting requirements to build wheel: started
        Getting requirements to build wheel: finished with status 'done'
        Preparing metadata (pyproject.toml): started
        Preparing metadata (pyproject.toml): finished with status 'error'
        error: subprocess-exited-with-error

        × Preparing metadata (pyproject.toml) did not run successfully.
        │ exit code: 1
        ╰─> [6 lines of output]
            usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
               or: setup.py --help [cmd1 cmd2 ...]
               or: setup.py --help-commands
               or: setup.py cmd --help

            error: invalid command 'dist_info'
            [end of output]

        note: This error originates from a subprocess, and is likely not a problem with pip.
      error: metadata-generation-failed

      × Encountered error while generating package metadata.
      ╰─> See above for output.

      note: This is an issue with the package mentioned above, not pip.
      hint: See above for details.
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install backend dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.
stijnvanhoey commented 1 year ago

Make sure you install pip install python-dotenv instead.

peterdesmet commented 1 year ago

Thanks that worked, the issue was that I hadn't installed the optional dependencies with:

pip install vptstools[transfer]

Since that command throw an error:

pip3 install vptstools[transfer] 
zsh: no matches found: vptstools[transfer]

Turns out I need to escape for zsh (rather than bash):

pip3 install vptstools\[transfer\]

Would the escaped commando also work for bash? If so, I would update in the README