miniufo / xgrads

Parse and read ctl and associated binary file commonly used by GrADS into xarray
https://xgrads.readthedocs.io/
MIT License
71 stars 27 forks source link

Add conda installation support #46

Closed jypeter closed 1 year ago

jypeter commented 1 year ago

I have tried to install xgrads with conda (with mamba actually) and I got a nothing provides requested xgrads error message

I then had a look at the xgrads GH page and found out that you currently can only use pip install xgrads. The pip installation worked

You may want to:

miniufo commented 1 year ago

Yes I do want to. I've tried twice but I failed somehow (do not remember now). Can you send me a (step by step) tutorial about how to do this?

jypeter commented 1 year ago

Unfortunately, I have absolutely no idea how this is done!

I only maintain a python distribution in our lab with lots of different packages coming from conda-forge. Lots means I have to use mamba instead of conda for installation. Otherwise conda can't solve the depencies and gets stuck

miniufo commented 1 year ago

I just made a conda package at my channel. I also made one to conda-forge (sent a PR), but it needs some time for them to build. Maybe you can try the one on my channel?

Thanks for pushing me on this. Haha

miniufo commented 1 year ago

It is now added to the conda-forge here. Closing this issue. Thanks @jypeter.

jypeter commented 1 year ago

Thanks @miniufo !

For the record, everything went perfectly well when I uninstalled the pip version, and then installed the conda-forge version instead

 >conda list | grep -i grads
xgrads                    0.2.3                    pypi_0    pypi

 >pip uninstall xgrads
Found existing installation: xgrads 0.2.3
Uninstalling xgrads-0.2.3:
  Would remove:
    /home/share/unix_files/cdat/miniconda3_21-02/envs/cdatm19_nompi_py3/lib/python3.8/site-packages/xgrads-0.2.3.dist-info/*
    /home/share/unix_files/cdat/miniconda3_21-02/envs/cdatm19_nompi_py3/lib/python3.8/site-packages/xgrads/*
Proceed (Y/n)? Y
  Successfully uninstalled xgrads-0.2.3

>conda list | grep -i grads

 >mamba install xgrads

[...]
Looking for: ['xgrads']

pkgs/main/noarch                                              No change
pkgs/r/linux-64                                      1.5MB @   2.8MB/s  0.7s
pkgs/r/noarch                                        1.3MB @   1.5MB/s  0.7s
pkgs/main/linux-64                                   6.1MB @   3.5MB/s  2.0s
conda-forge/noarch                                  14.0MB @   3.9MB/s  4.2s
conda-forge/linux-64                                34.4MB @   4.0MB/s 10.1s

Pinned packages:
  - python 3.8.*

Transaction

  Prefix: /home/share/unix_files/cdat/miniconda3_21-02/envs/cdatm_py3

  Updating specs:

   - xgrads
   - ca-certificates
   - certifi
   - openssl

  Package   Version  Build         Channel                Size
────────────────────────────────────────────────────────────────
  Install:
────────────────────────────────────────────────────────────────

  + xgrads    0.2.6  pyhd8ed1ab_0  conda-forge/noarch     26kB

  Summary:

  Install: 1 packages

  Total download: 26kB

────────────────────────────────────────────────────────────────

Confirm changes: [Y/n] Y
xgrads                                              26.2kB @ 109.1kB/s  0.2s
Preparing transaction: done
Verifying transaction: done
Executing transaction: done

 >conda list | grep -i grads
xgrads                    0.2.6              pyhd8ed1ab_0    conda-forge