From 5b2103c3a9c76acc0fcb8c48af15a39ebcfbaa4c Mon Sep 17 00:00:00 2001 From: tsutterley Date: Fri, 13 Sep 2024 15:31:18 -0700 Subject: [PATCH] chore: improve optional dependencies in build --- IS2view/utilities.py | 4 +-- MANIFEST.in | 1 - README.rst | 40 +++++++++++++++++++++++++- doc/source/getting_started/Install.rst | 8 +++--- pyproject.toml | 2 +- 5 files changed, 46 insertions(+), 9 deletions(-) diff --git a/IS2view/utilities.py b/IS2view/utilities.py index 783690e..e91d6bd 100644 --- a/IS2view/utilities.py +++ b/IS2view/utilities.py @@ -121,7 +121,7 @@ def import_dependency( # PURPOSE: get the hash value of a file def get_hash( local: str | io.IOBase | pathlib.Path, - algorithm: str = 'MD5' + algorithm: str = 'md5' ): """ Get the hash value from a local file or ``BytesIO`` object @@ -130,7 +130,7 @@ def get_hash( ---------- local: obj, str or pathlib.Path BytesIO object or path to file - algorithm: str, default 'MD5' + algorithm: str, default 'md5' hashing algorithm for checksum validation """ # check if open file object or if local file exists diff --git a/MANIFEST.in b/MANIFEST.in index 22c8634..7135f1b 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -3,5 +3,4 @@ prune doc* prune notebooks* exclude *.cfg exclude *.yml -include requirements.txt include version.txt diff --git a/README.rst b/README.rst index fed1d95..4ca56a2 100644 --- a/README.rst +++ b/README.rst @@ -33,6 +33,39 @@ Interactive visualization and data extraction tool for ICESat-2 ATL14/15 Gridded - https://icesat-2-scf.gsfc.nasa.gov - https://nsidc.org/data/icesat-2/ +For more information: see the documentation at `is2view.readthedocs.io `_ + +Installation +############ + +From PyPI: + +.. code-block:: bash + + python3 -m pip install IS2view + +To include all optional dependencies: + +.. code-block:: bash + + python3 -m pip install IS2view[all] + +Using `conda` or `mamba` from conda-forge: + +.. code-block:: bash + + conda install -c conda-forge is2view + +.. code-block:: bash + + mamba install -c conda-forge is2view + +Development version from GitHub: + +.. code-block:: bash + + python3 -m pip install git+https://github.com/tsutterley/IS2view.git + Dependencies ############ @@ -53,10 +86,15 @@ Download | A zip archive of the latest version is available directly at: | https://github.com/tsutterley/IS2view/archive/main.zip +Contributing +############ + +This project contains work and contributions from the `scientific community <./CONTRIBUTORS.rst>`_. +If you would like to contribute to the project, please have a look at the `open issues `_ and the project `code of conduct <./CODE_OF_CONDUCT.rst>`_. + Disclaimer ########## -This project contains work and contributions from the `scientific community <./CONTRIBUTORS.rst>`_. This program is not sponsored or maintained by the Universities Space Research Association (USRA) or NASA. It is provided here for your convenience but *with no guarantees whatsoever*. diff --git a/doc/source/getting_started/Install.rst b/doc/source/getting_started/Install.rst index 5f2169e..f1a93d8 100644 --- a/doc/source/getting_started/Install.rst +++ b/doc/source/getting_started/Install.rst @@ -24,17 +24,17 @@ To use the development repository, please fork ``IS2view`` into your own account git clone https://github.com/tsutterley/IS2view.git -``IS2view`` can then be installed within the package directory using ``setuptools``: +``IS2view`` can then be installed within the package directory using ``pip``: .. code-block:: bash - python3 setup.py install + python3 -m pip install --user . -or ``pip`` +To include all optional dependencies: .. code-block:: bash - python3 -m pip install --user . + python3 -m pip install --user .[all] The development version of ``IS2view`` can also be installed directly from GitHub using ``pip``: diff --git a/pyproject.toml b/pyproject.toml index a65564c..911eff0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -60,7 +60,7 @@ Issues = "https://github.com/tsutterley/IS2view/issues" [project.optional-dependencies] doc = ["docutils", "graphviz", "ipywidgets", "notebook", "numpydoc", "sphinx", "sphinx-argparse>=0.4", "sphinx_rtd_theme"] -all = ["ipywidgets", "notebook"] +all = ["boto3", "bottleneck", "dask", "geopandas", "ipywidgets", "notebook", "owslib", "s3fs", "xyzservices", "zarr"] dev = ["flake8", "pytest>=4.6", "pytest-cov"] [tool.setuptools.packages.find]