diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..78a3ce4 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,18 @@ +name: CI +on: [push, pull_request] + +permissions: + contents: read + +jobs: + test: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-python@v4 + with: + python-version: "3.12" + - run: pip install poetry + + - run: poetry install --with dev --no-interaction + - run: poetry run pytest -q || [ $? -eq 5 ] diff --git a/poetry.lock b/poetry.lock index 27a517b..3cc5a88 100644 --- a/poetry.lock +++ b/poetry.lock @@ -50,7 +50,6 @@ description = "High level compatibility layer for multiple asynchronous event lo optional = false python-versions = ">=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "anyio-4.9.0-py3-none-any.whl", hash = "sha256:9f76d541cad6e36af7beb62e978876f3b41e3e04f2c1fbf0884604c0a9c4d93c"}, {file = "anyio-4.9.0.tar.gz", hash = "sha256:673c0c244e15788651a4ff38710fea9675823028a6f08a5eda409e0c9840a028"}, @@ -205,48 +204,6 @@ files = [ {file = "blinker-1.9.0.tar.gz", hash = "sha256:b4ce2265a7abece45e7cc896e98dbebe6cead56bcf805a3d23136d145f5445bf"}, ] -[[package]] -name = "boto3" -version = "1.38.32" -description = "The AWS SDK for Python" -optional = false -python-versions = ">=3.9" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "boto3-1.38.32-py3-none-any.whl", hash = "sha256:b998edac72f6740bd5d9d585cf3880f2dfeb4842e626b34430fd0e9623378011"}, - {file = "boto3-1.38.32.tar.gz", hash = "sha256:3faa2c328a61745f3215a63039606a6fcf55d9afe1cc76e3a5e27b9db58cdbf6"}, -] - -[package.dependencies] -botocore = ">=1.38.32,<1.39.0" -jmespath = ">=0.7.1,<2.0.0" -s3transfer = ">=0.13.0,<0.14.0" - -[package.extras] -crt = ["botocore[crt] (>=1.21.0,<2.0a0)"] - -[[package]] -name = "botocore" -version = "1.38.32" -description = "Low-level, data-driven core of boto 3." -optional = false -python-versions = ">=3.9" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "botocore-1.38.32-py3-none-any.whl", hash = "sha256:64ab919a5d8b74dd73eaac1f978d0e674d11ff3bbe8815c3d2982477be9a082c"}, - {file = "botocore-1.38.32.tar.gz", hash = "sha256:0899a090e352cb5eeaae2c7bb52a987b469d23912c7ece86664dfb5c2e074978"}, -] - -[package.dependencies] -jmespath = ">=0.7.1,<2.0.0" -python-dateutil = ">=2.1,<3.0.0" -urllib3 = {version = ">=1.25.4,<2.2.0 || >2.2.0,<3", markers = "python_version >= \"3.10\""} - -[package.extras] -crt = ["awscrt (==0.23.8)"] - [[package]] name = "bqplot" version = "0.12.45" @@ -300,7 +257,6 @@ description = "Extensible memoizing collections and decorators" optional = false python-versions = ">=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "cachetools-6.0.0-py3-none-any.whl", hash = "sha256:82e73ba88f7b30228b5507dce1a1f878498fc669d972aef2dde4f3a3c24f103e"}, {file = "cachetools-6.0.0.tar.gz", hash = "sha256:f225782b84438f828328fc2ad74346522f27e5b1440f4e9fd18b20ebfd1aa2cf"}, @@ -465,26 +421,6 @@ click = ">=4.0" [package.extras] dev = ["coveralls", "pytest (>=3.6)", "pytest-cov", "wheel"] -[[package]] -name = "cligj" -version = "0.4.0" -description = "Click params for commmand line interfaces to GeoJSON" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "cligj-0.4.0-py2-none-any.whl", hash = "sha256:7588487f1afcefbe65ae477cdbd4fca1828a3000fc3332e165dacb1dcb005f8a"}, - {file = "cligj-0.4.0-py3-none-any.whl", hash = "sha256:2efdeb0ae64f2c2198ce7540ae0a5d67187d5fe9d79529ad8f4dbb8909210009"}, - {file = "cligj-0.4.0.tar.gz", hash = "sha256:12ad07994f5c1173b06087ffbaacec52f9ebe4687926e5aacfc22b6b0c8b3f54"}, -] - -[package.dependencies] -click = ">=4.0" - -[package.extras] -test = ["pytest-cov"] - [[package]] name = "cligj" version = "0.7.2" @@ -492,7 +428,6 @@ description = "Click params for commmand line interfaces to GeoJSON" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, <4" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "cligj-0.7.2-py3-none-any.whl", hash = "sha256:c1ca117dbce1fe20a5809dc96f01e1c2840f6dcc939b3ddbb1111bf330ba82df"}, {file = "cligj-0.7.2.tar.gz", hash = "sha256:a4bc13d623356b373c2c27c53dbd9c68cae5d526270bfa71f6c6fa69669c6b27"}, @@ -511,7 +446,6 @@ description = "Apply basic color-oriented image operations." optional = false python-versions = ">=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "color_operations-0.2.0-cp310-cp310-macosx_10_9_universal2.whl", hash = "sha256:b5119c3136f0f18e470ac7ff95b0a92899b450d63a6bbe518f1b0ca6e2c88685"}, {file = "color_operations-0.2.0-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:f92bdf4341c0516e1779ac3e3db83b871af2d989b210b6bd713ef46ead5705dd"}, @@ -791,7 +725,6 @@ description = "Parse Python docstrings in reST, Google and Numpydoc format" optional = false python-versions = ">=3.6,<4.0" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "docstring_parser-0.16-py3-none-any.whl", hash = "sha256:bf0a1387354d3691d102edef7ec124f219ef639982d096e26e3b60aeffa90637"}, {file = "docstring_parser-0.16.tar.gz", hash = "sha256:538beabd0af1e2db0146b6bd3caa526c35a34d61af9fd2887f3a8a27a739aa6e"}, @@ -934,22 +867,6 @@ files = [ cachelib = ">=0.9.0" Flask = "*" -[[package]] -name = "flask-cors" -version = "5.0.0" -description = "A Flask extension adding a decorator for CORS support" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "Flask_Cors-5.0.0-py2.py3-none-any.whl", hash = "sha256:b9e307d082a9261c100d8fb0ba909eec6a228ed1b60a8315fd85f783d61910bc"}, - {file = "flask_cors-5.0.0.tar.gz", hash = "sha256:5aadb4b950c4e93745034594d9f3ea6591f734bb3662e16e255ffbf5e89c88ef"}, -] - -[package.dependencies] -Flask = ">=0.9" - [[package]] name = "flask-cors" version = "6.0.0" @@ -957,7 +874,6 @@ description = "A Flask extension simplifying CORS support" optional = false python-versions = "<4.0,>=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "flask_cors-6.0.0-py3-none-any.whl", hash = "sha256:6332073356452343a8ccddbfec7befdc3fdd040141fe776ec9b94c262f058657"}, {file = "flask_cors-6.0.0.tar.gz", hash = "sha256:4592c1570246bf7beee96b74bc0adbbfcb1b0318f6ba05c412e8909eceec3393"}, @@ -1254,7 +1170,6 @@ description = "A minimal low-level HTTP client." optional = false python-versions = ">=3.8" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "httpcore-1.0.9-py3-none-any.whl", hash = "sha256:2d400746a40668fc9dec9810239072b40b4484b640a8c38fd654a024c7a1bf55"}, {file = "httpcore-1.0.9.tar.gz", hash = "sha256:6e34463af53fd2ab5d807f399a9b45ea31c3dfa2276f15a2c3f00afff6e176e8"}, @@ -1277,7 +1192,6 @@ description = "The next generation HTTP client." optional = false python-versions = ">=3.8" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "httpx-0.28.1-py3-none-any.whl", hash = "sha256:d909fcccc110f8c7faf814ca82a9a4d816bc5a6dbfea25d6591d6985b8ba59ad"}, {file = "httpx-0.28.1.tar.gz", hash = "sha256:75e98c5f16b0f35b567856f597f06ff2270a374470a5c2392242528e3e3e42fc"}, @@ -1627,19 +1541,6 @@ MarkupSafe = ">=2.0" [package.extras] i18n = ["Babel (>=2.7)"] -[[package]] -name = "jmespath" -version = "1.0.1" -description = "JSON Matching Expressions" -optional = false -python-versions = ">=3.7" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "jmespath-1.0.1-py3-none-any.whl", hash = "sha256:02e2e4cc71b5bcab88332eebf907519190dd9e6e82107fa7f83b1003a6252980"}, - {file = "jmespath-1.0.1.tar.gz", hash = "sha256:90261b206d6defd58fdd5e85f478bf633a2901798906be2ad389150c5c60edbe"}, -] - [[package]] name = "jsonschema" version = "4.24.0" @@ -1882,7 +1783,6 @@ description = "Python port of markdown-it. Markdown parsing, done right!" optional = false python-versions = ">=3.8" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "markdown-it-py-3.0.0.tar.gz", hash = "sha256:e3f60a94fa066dc52ec76661e37c851cb232d92f9886b15cb560aaada2df8feb"}, {file = "markdown_it_py-3.0.0-py3-none-any.whl", hash = "sha256:355216845c60bd96232cd8d8c40e8f9765cc86f46880e43a8fd22dc1a1a8cab1"}, @@ -2052,32 +1952,11 @@ description = "Markdown URL utilities" optional = false python-versions = ">=3.7" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "mdurl-0.1.2-py3-none-any.whl", hash = "sha256:84008a41e51615a49fc9966191ff91509e3c40b939176e643fd50a5c2196b8f8"}, {file = "mdurl-0.1.2.tar.gz", hash = "sha256:bb413d29f5eea38f31dd4754dd7377d4465116fb207585f97bf925588687c1ba"}, ] -[[package]] -name = "mercantile" -version = "1.2.1" -description = "Web mercator XYZ tile utilities" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "mercantile-1.2.1-py3-none-any.whl", hash = "sha256:30f457a73ee88261aab787b7069d85961a5703bb09dc57a170190bc042cd023f"}, - {file = "mercantile-1.2.1.tar.gz", hash = "sha256:fa3c6db15daffd58454ac198b31887519a19caccee3f9d63d17ae7ff61b3b56b"}, -] - -[package.dependencies] -click = ">=3.0" - -[package.extras] -dev = ["check-manifest"] -test = ["hypothesis", "pytest"] - [[package]] name = "morecantile" version = "6.2.0" @@ -2085,7 +1964,6 @@ description = "Construct and use map tile grids (a.k.a TileMatrixSet / TMS)." optional = false python-versions = ">=3.8" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "morecantile-6.2.0-py3-none-any.whl", hash = "sha256:a3cc8f85c6afcddb6c2ec933ad692557f96e89689730dbbd4350bdcf6ac52be0"}, {file = "morecantile-6.2.0.tar.gz", hash = "sha256:65c7150ea68bbe16ee6f75f3f171ac1ae51ab26e7a77c92a768048f40f916412"}, @@ -2256,53 +2134,6 @@ files = [ [package.dependencies] numpy = ">=1.23.0" -[[package]] -name = "numpy" -version = "1.26.4" -description = "Fundamental package for array computing in Python" -optional = false -python-versions = ">=3.9" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "numpy-1.26.4-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:9ff0f4f29c51e2803569d7a51c2304de5554655a60c5d776e35b4a41413830d0"}, - {file = "numpy-1.26.4-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:2e4ee3380d6de9c9ec04745830fd9e2eccb3e6cf790d39d7b98ffd19b0dd754a"}, - {file = "numpy-1.26.4-cp310-cp310-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d209d8969599b27ad20994c8e41936ee0964e6da07478d6c35016bc386b66ad4"}, - {file = "numpy-1.26.4-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:ffa75af20b44f8dba823498024771d5ac50620e6915abac414251bd971b4529f"}, - {file = "numpy-1.26.4-cp310-cp310-musllinux_1_1_aarch64.whl", hash = "sha256:62b8e4b1e28009ef2846b4c7852046736bab361f7aeadeb6a5b89ebec3c7055a"}, - {file = "numpy-1.26.4-cp310-cp310-musllinux_1_1_x86_64.whl", hash = "sha256:a4abb4f9001ad2858e7ac189089c42178fcce737e4169dc61321660f1a96c7d2"}, - {file = "numpy-1.26.4-cp310-cp310-win32.whl", hash = "sha256:bfe25acf8b437eb2a8b2d49d443800a5f18508cd811fea3181723922a8a82b07"}, - {file = "numpy-1.26.4-cp310-cp310-win_amd64.whl", hash = "sha256:b97fe8060236edf3662adfc2c633f56a08ae30560c56310562cb4f95500022d5"}, - {file = "numpy-1.26.4-cp311-cp311-macosx_10_9_x86_64.whl", hash = "sha256:4c66707fabe114439db9068ee468c26bbdf909cac0fb58686a42a24de1760c71"}, - {file = "numpy-1.26.4-cp311-cp311-macosx_11_0_arm64.whl", hash = "sha256:edd8b5fe47dab091176d21bb6de568acdd906d1887a4584a15a9a96a1dca06ef"}, - {file = "numpy-1.26.4-cp311-cp311-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:7ab55401287bfec946ced39700c053796e7cc0e3acbef09993a9ad2adba6ca6e"}, - {file = "numpy-1.26.4-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:666dbfb6ec68962c033a450943ded891bed2d54e6755e35e5835d63f4f6931d5"}, - {file = "numpy-1.26.4-cp311-cp311-musllinux_1_1_aarch64.whl", hash = "sha256:96ff0b2ad353d8f990b63294c8986f1ec3cb19d749234014f4e7eb0112ceba5a"}, - {file = "numpy-1.26.4-cp311-cp311-musllinux_1_1_x86_64.whl", hash = "sha256:60dedbb91afcbfdc9bc0b1f3f402804070deed7392c23eb7a7f07fa857868e8a"}, - {file = "numpy-1.26.4-cp311-cp311-win32.whl", hash = "sha256:1af303d6b2210eb850fcf03064d364652b7120803a0b872f5211f5234b399f20"}, - {file = "numpy-1.26.4-cp311-cp311-win_amd64.whl", hash = "sha256:cd25bcecc4974d09257ffcd1f098ee778f7834c3ad767fe5db785be9a4aa9cb2"}, - {file = "numpy-1.26.4-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:b3ce300f3644fb06443ee2222c2201dd3a89ea6040541412b8fa189341847218"}, - {file = "numpy-1.26.4-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:03a8c78d01d9781b28a6989f6fa1bb2c4f2d51201cf99d3dd875df6fbd96b23b"}, - {file = "numpy-1.26.4-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:9fad7dcb1aac3c7f0584a5a8133e3a43eeb2fe127f47e3632d43d677c66c102b"}, - {file = "numpy-1.26.4-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:675d61ffbfa78604709862923189bad94014bef562cc35cf61d3a07bba02a7ed"}, - {file = "numpy-1.26.4-cp312-cp312-musllinux_1_1_aarch64.whl", hash = "sha256:ab47dbe5cc8210f55aa58e4805fe224dac469cde56b9f731a4c098b91917159a"}, - {file = "numpy-1.26.4-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:1dda2e7b4ec9dd512f84935c5f126c8bd8b9f2fc001e9f54af255e8c5f16b0e0"}, - {file = "numpy-1.26.4-cp312-cp312-win32.whl", hash = "sha256:50193e430acfc1346175fcbdaa28ffec49947a06918b7b92130744e81e640110"}, - {file = "numpy-1.26.4-cp312-cp312-win_amd64.whl", hash = "sha256:08beddf13648eb95f8d867350f6a018a4be2e5ad54c8d8caed89ebca558b2818"}, - {file = "numpy-1.26.4-cp39-cp39-macosx_10_9_x86_64.whl", hash = "sha256:7349ab0fa0c429c82442a27a9673fc802ffdb7c7775fad780226cb234965e53c"}, - {file = "numpy-1.26.4-cp39-cp39-macosx_11_0_arm64.whl", hash = "sha256:52b8b60467cd7dd1e9ed082188b4e6bb35aa5cdd01777621a1658910745b90be"}, - {file = "numpy-1.26.4-cp39-cp39-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:d5241e0a80d808d70546c697135da2c613f30e28251ff8307eb72ba696945764"}, - {file = "numpy-1.26.4-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:f870204a840a60da0b12273ef34f7051e98c3b5961b61b0c2c1be6dfd64fbcd3"}, - {file = "numpy-1.26.4-cp39-cp39-musllinux_1_1_aarch64.whl", hash = "sha256:679b0076f67ecc0138fd2ede3a8fd196dddc2ad3254069bcb9faf9a79b1cebcd"}, - {file = "numpy-1.26.4-cp39-cp39-musllinux_1_1_x86_64.whl", hash = "sha256:47711010ad8555514b434df65f7d7b076bb8261df1ca9bb78f53d3b2db02e95c"}, - {file = "numpy-1.26.4-cp39-cp39-win32.whl", hash = "sha256:a354325ee03388678242a4d7ebcd08b5c727033fcff3b2f536aea978e15ee9e6"}, - {file = "numpy-1.26.4-cp39-cp39-win_amd64.whl", hash = "sha256:3373d5d70a5fe74a2c1bb6d2cfd9609ecf686d47a2d7b1d37a8f3b6bf6003aea"}, - {file = "numpy-1.26.4-pp39-pypy39_pp73-macosx_10_9_x86_64.whl", hash = "sha256:afedb719a9dcfc7eaf2287b839d8198e06dcd4cb5d276a3df279231138e83d30"}, - {file = "numpy-1.26.4-pp39-pypy39_pp73-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:95a7476c59002f2f6c590b9b7b998306fba6a5aa646b1e22ddfeaf8f78c3a29c"}, - {file = "numpy-1.26.4-pp39-pypy39_pp73-win_amd64.whl", hash = "sha256:7e50d0a0cc3189f9cb0aeb3a6a6af18c16f59f004b866cd2be1c14b36134a4a0"}, - {file = "numpy-1.26.4.tar.gz", hash = "sha256:2a02aba9ed12e4ac4eb3ea9421c420301a0c6460d9830d74a9df87efa4912010"}, -] - [[package]] name = "numpy" version = "2.2.6" @@ -2310,7 +2141,6 @@ description = "Fundamental package for array computing in Python" optional = false python-versions = ">=3.10" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "numpy-2.2.6-cp310-cp310-macosx_10_9_x86_64.whl", hash = "sha256:b412caa66f72040e6d268491a59f2c43bf03eb6c96dd8f0307829feb7fa2b6fb"}, {file = "numpy-2.2.6-cp310-cp310-macosx_11_0_arm64.whl", hash = "sha256:8e41fd67c52b86603a91c1a505ebaef50b3314de0213461c7a6e99c9a3beff90"}, @@ -2369,34 +2199,6 @@ files = [ {file = "numpy-2.2.6.tar.gz", hash = "sha256:e29554e2bef54a90aa5cc07da6ce955accb83f21ab5de01a62c8478897b264fd"}, ] -[[package]] -name = "opera-utils" -version = "0.19.0" -description = "Miscellaneous utilities for working with OPERA data products" -optional = false -python-versions = ">=3.9" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "opera_utils-0.19.0-py3-none-any.whl", hash = "sha256:f8b9bf814c19fa4c2d93d2f2fcfd8f5ec7190847a8c921fe9562fee2be64207f"}, - {file = "opera_utils-0.19.0.tar.gz", hash = "sha256:33d30fa8fcee01dd418914d4e14a5c15f751fbb7dc0c30aca18524a6ddf4ca96"}, -] - -[package.dependencies] -click = ">=7.0" -h5py = ">=1.10" -numpy = ">=1.24" -pooch = ">=1.7" -pyproj = ">=3.3" -shapely = ">=1.8" -typing_extensions = ">=4" - -[package.extras] -docs = ["mkdocs", "mkdocs-gen-files", "mkdocs-jupyter", "mkdocs-literate-nav", "mkdocs-material", "mkdocs-section-index", "mkdocstrings[python]", "pybtex", "pymdown-extensions"] -geopandas = ["geopandas", "pyogrio"] -remote = ["aiohttp", "fsspec", "s3fs"] -test = ["asf_search", "geopandas", "pre-commit", "pyogrio", "pytest", "pytest-cov", "pytest-randomly", "pytest-recording", "pytest-xdist", "ruff"] - [[package]] name = "opera-utils" version = "0.22.1" @@ -2404,7 +2206,6 @@ description = "Miscellaneous utilities for working with OPERA data products" optional = false python-versions = ">=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "opera_utils-0.22.1-py3-none-any.whl", hash = "sha256:13f5ab63cba6fde4887ea779faa83ec235917fd0e9817d87b5fa591b2abd46ea"}, {file = "opera_utils-0.22.1.tar.gz", hash = "sha256:34ce446925a22d7a85506f783c6a31a6b188f695ce7542cf253050a4c07540dc"}, @@ -3407,44 +3208,6 @@ files = [ {file = "pyyaml-6.0.2.tar.gz", hash = "sha256:d584d9ec91ad65861cc08d42e834324ef890a082e591037abe114850ff7bbc3e"}, ] -[[package]] -name = "rasterio" -version = "1.0.6" -description = "Fast and direct raster I/O for use with Numpy and SciPy" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "rasterio-1.0.6-cp27-cp27m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:542c89fe3799b25eebd002da92dd1fe023c6d229e395dd8b3d1a1516131bed38"}, - {file = "rasterio-1.0.6-cp27-cp27mu-manylinux1_x86_64.whl", hash = "sha256:c65a9ebdddbdea0e0f6eb930f5582939b953391b160cae15ceb98d7496f82688"}, - {file = "rasterio-1.0.6-cp34-cp34m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:5c40f824390872e6487dc9bf5ba94d7e92a7eb619425c5d6f676afd3a6c7d9ee"}, - {file = "rasterio-1.0.6-cp35-cp35m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:b5fff484c58596f677c0a4fbed4efc921546569f3fa9b525d148068caf32893f"}, - {file = "rasterio-1.0.6-cp35-cp35m-manylinux1_x86_64.whl", hash = "sha256:a258bf13d0c4f96f2302c63f79f69b86f58a6e107b29edd983facd822992ddc3"}, - {file = "rasterio-1.0.6-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:5089144301533811983e37977c4bd18cfc81cb6ec2a8a66627530864a1794c8a"}, - {file = "rasterio-1.0.6-cp36-cp36m-manylinux1_x86_64.whl", hash = "sha256:27e65b19f9f22cadfc553644229bed402469dd84a6db29dc2107c1ae5e5c2a23"}, - {file = "rasterio-1.0.6-cp37-cp37m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl", hash = "sha256:8800da3575aff6fed43d65d960a3e6816ae67a9a9e726d614bd022117a19e61c"}, - {file = "rasterio-1.0.6-cp37-cp37m-manylinux1_x86_64.whl", hash = "sha256:0a07fe85992076b508230dcb95420b4a711d1523bbcc2a5904b60f25a7301f15"}, - {file = "rasterio-1.0.6.tar.gz", hash = "sha256:b3c6a10f17cc8477b677f4e3743684f6591d67cb289c3f676f8850c9bf0de564"}, -] - -[package.dependencies] -affine = "*" -attrs = "*" -boto3 = {version = ">=1.2.4", optional = true, markers = "extra == \"s3\""} -click-plugins = "*" -cligj = "*" -numpy = "*" -snuggs = ">=1.4.1" - -[package.extras] -all = ["boto3 (>=1.2.4)", "ghp-import", "hypothesis", "ipython (>=2.0)", "matplotlib", "numpydoc", "packaging", "pytest (>=2.8.2)", "pytest-cov (>=2.2.0)", "sphinx", "sphinx-rtd-theme"] -docs = ["ghp-import", "numpydoc", "sphinx", "sphinx-rtd-theme"] -ipython = ["ipython (>=2.0)"] -plot = ["matplotlib"] -s3 = ["boto3 (>=1.2.4)"] -test = ["boto3 (>=1.2.4)", "hypothesis", "packaging", "pytest (>=2.8.2)", "pytest-cov (>=2.2.0)"] - [[package]] name = "rasterio" version = "1.4.3" @@ -3452,7 +3215,6 @@ description = "Fast and direct raster I/O for use with Numpy and SciPy" optional = false python-versions = ">=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "rasterio-1.4.3-cp310-cp310-macosx_10_15_x86_64.whl", hash = "sha256:80f994b92e5dda78f13291710bd5c43efcfd164f69a8a2c20489115df9d178c8"}, {file = "rasterio-1.4.3-cp310-cp310-macosx_14_0_arm64.whl", hash = "sha256:1a6e6ca9ec361599b48c9918ce25adb1a9203b8c8ca9b34ad78dccb3aef7945a"}, @@ -3542,7 +3304,6 @@ description = "Render rich text, tables, progress bars, syntax highlighting, mar optional = false python-versions = ">=3.8.0" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "rich-14.0.0-py3-none-any.whl", hash = "sha256:1c9491e1951aac09caffd42f448ee3d04e58923ffe14993f6e83068dc395d7e0"}, {file = "rich-14.0.0.tar.gz", hash = "sha256:82f1bc23a6a21ebca4ae0c45af9bdbc492ed20231dcb63f297d6d1021a9d5725"}, @@ -3556,29 +3317,6 @@ typing-extensions = {version = ">=4.0.0,<5.0", markers = "python_version < \"3.1 [package.extras] jupyter = ["ipywidgets (>=7.5.1,<9)"] -[[package]] -name = "rio-cogeo" -version = "1.1.0" -description = "CloudOptimized GeoTIFF (COGEO) creation plugin for rasterio" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "rio-cogeo-1.1.0.tar.gz", hash = "sha256:250777ed283811ce6c363e8ef108c382b451465206be68973807bf2ae80cc8f3"}, -] - -[package.dependencies] -click = "*" -mercantile = "*" -numpy = ">=1.15,<2.0" -rasterio = {version = ">=1.0.1", extras = ["s3"]} -supermercado = "*" - -[package.extras] -dev = ["cogdumper", "pre-commit", "pytest", "pytest-cov", "rio-tiler"] -test = ["cogdumper", "pytest", "pytest-cov", "rio-tiler"] - [[package]] name = "rio-cogeo" version = "5.4.1" @@ -3586,7 +3324,6 @@ description = "Cloud Optimized GeoTIFF (COGEO) creation plugin for rasterio" optional = false python-versions = ">=3.8" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "rio_cogeo-5.4.1-py3-none-any.whl", hash = "sha256:7387f8e523759c694313158be99be0581a6d115862d3f764d553a42a8b2278f6"}, {file = "rio_cogeo-5.4.1.tar.gz", hash = "sha256:2d7de85e4d6655698f6eb871d9ea62d645a855dfcdfbae7dc4bd08ed892d555b"}, @@ -3603,51 +3340,6 @@ dev = ["pre-commit"] docs = ["mkdocs", "mkdocs-material"] test = ["cogdumper", "pytest", "pytest-cov"] -[[package]] -name = "rio-mucho" -version = "1.0.0" -description = "Windowed multiprocessing wrapper for rasterio" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "rio-mucho-1.0.0.tar.gz", hash = "sha256:606f662e4cc0c7efb98dd7a1eb4df9d93022a305d187b6c02574c4542593b590"}, - {file = "rio_mucho-1.0.0-py2-none-any.whl", hash = "sha256:156eb911521969e4a795ab438e02c9ac5bf5b441806fa78e556f0d1ea113a27c"}, - {file = "rio_mucho-1.0.0-py3-none-any.whl", hash = "sha256:4677aca0613b35b1eb6dcdf314eafc23b707c42e54e9af89a87c86df5ae1ba6c"}, -] - -[package.dependencies] -numpy = "*" -rasterio = ">=1.0,<2.0" - -[package.extras] -test = ["coveralls", "pytest", "pytest-cov"] - -[[package]] -name = "rio-tiler" -version = "1.2.11" -description = "Get mercator tile from CloudOptimized GeoTIFF and other cloud hosted raster such as CBERS-4, Sentinel-2 and Landsat-8 AWS PDS" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "rio-tiler-1.2.11.tar.gz", hash = "sha256:41b49c23e5e12e84b6e911f7e392e44b9475829282de77fb7ff15ac269440b3c"}, -] - -[package.dependencies] -boto3 = "*" -mercantile = "*" -numexpr = "*" -numpy = "*" -rasterio = {version = ">=1.0,<2.0", extras = ["s3"]} -rio-toa = "*" - -[package.extras] -dev = ["mock", "pre-commit", "pytest", "pytest-cov"] -test = ["mock", "pytest", "pytest-cov"] - [[package]] name = "rio-tiler" version = "7.8.0" @@ -3655,7 +3347,6 @@ description = "User friendly Rasterio plugin to read raster datasets." optional = false python-versions = ">=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "rio_tiler-7.8.0-py3-none-any.whl", hash = "sha256:7df4e8770782d31aec772b99570d3561d308f6fe5c5355cb1dd66c8ff88fcf7d"}, {file = "rio_tiler-7.8.0.tar.gz", hash = "sha256:0e0d658d35d7bd308a3793b6eb1bb75d6783587bca0a33b9c2c5b25788e3b159"}, @@ -3683,50 +3374,6 @@ test = ["boto3", "h5netcdf", "morecantile (>=6.0,<7.0)", "pytest", "pytest-cov", tilebench = ["pytest", "tilebench"] xarray = ["rioxarray", "xarray"] -[[package]] -name = "rio-toa" -version = "0.3.0" -description = "Top Of Atmosphere (TOA) calculations for Landsat 8" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "rio-toa-0.3.0.tar.gz", hash = "sha256:2b905432d1b68addd0a27966b52a075d62845fb4232758ce767559dfa67b7e22"}, -] - -[package.dependencies] -click = "*" -rasterio = "*" -rio-mucho = "*" - -[package.extras] -test = ["codecov", "hypothesis", "pytest", "pytest-cov"] - -[[package]] -name = "rioxarray" -version = "0.10.0" -description = "rasterio xarray extension." -optional = false -python-versions = ">=3.8" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "rioxarray-0.10.0.tar.gz", hash = "sha256:da58be8e1f5c6d03c75cffc13480208c8f47eaba4fb5371ed8fb61eadf818144"}, -] - -[package.dependencies] -packaging = "*" -pyproj = ">=2.2" -rasterio = "*" -xarray = ">=0.17" - -[package.extras] -all = ["dask", "nbsphinx", "nbsphinx", "netcdf4", "pre-commit", "pylint", "pytest (>=3.6)", "pytest-cov", "pytest-timeout", "scipy", "sphinx-click", "sphinx-click", "sphinx_rtd_theme", "sphinx_rtd_theme"] -dev = ["dask", "nbsphinx", "netcdf4", "pre-commit", "pylint", "pytest (>=3.6)", "pytest-cov", "pytest-timeout", "sphinx-click", "sphinx_rtd_theme"] -doc = ["nbsphinx", "sphinx-click", "sphinx_rtd_theme"] -interp = ["scipy"] - [[package]] name = "rioxarray" version = "0.19.0" @@ -3734,7 +3381,6 @@ description = "geospatial xarray extension powered by rasterio" optional = false python-versions = ">=3.10" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "rioxarray-0.19.0-py3-none-any.whl", hash = "sha256:494ee4fff1781072d55ee5276f5d07b63d93b05093cb33b926a12186ba5bb8ef"}, {file = "rioxarray-0.19.0.tar.gz", hash = "sha256:7819a0036fd874c8c8e280447cbbe43d8dc72fc4a14ac7852a665b1bdb7d4b04"}, @@ -3906,25 +3552,6 @@ files = [ {file = "ruff-0.11.13.tar.gz", hash = "sha256:26fa247dc68d1d4e72c179e08889a25ac0c7ba4d78aecfc835d49cbfd60bf514"}, ] -[[package]] -name = "s3transfer" -version = "0.13.0" -description = "An Amazon S3 Transfer Manager" -optional = false -python-versions = ">=3.9" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "s3transfer-0.13.0-py3-none-any.whl", hash = "sha256:0148ef34d6dd964d0d8cf4311b2b21c474693e57c2e069ec708ce043d2b527be"}, - {file = "s3transfer-0.13.0.tar.gz", hash = "sha256:f5e6db74eb7776a37208001113ea7aa97695368242b364d73e91c981ac522177"}, -] - -[package.dependencies] -botocore = ">=1.37.4,<2.0a.0" - -[package.extras] -crt = ["botocore[crt] (>=1.37.4,<2.0a.0)"] - [[package]] name = "scooby" version = "0.10.1" @@ -4022,7 +3649,6 @@ description = "Automagic shell tab completion for Python CLI applications" optional = false python-versions = ">=3.7" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "shtab-1.7.2-py3-none-any.whl", hash = "sha256:858a5805f6c137bb0cda4f282d27d08fd44ca487ab4a6a36d2a400263cd0b5c1"}, {file = "shtab-1.7.2.tar.gz", hash = "sha256:8c16673ade76a2d42417f03e57acf239bfb5968e842204c17990cae357d07d6f"}, @@ -4050,32 +3676,11 @@ description = "Sniff out which async library your code is running under" optional = false python-versions = ">=3.7" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "sniffio-1.3.1-py3-none-any.whl", hash = "sha256:2f6da418d1f1e0fddd844478f41680e794e6051915791a034ff65e5f100525a2"}, {file = "sniffio-1.3.1.tar.gz", hash = "sha256:f4324edc670a0f49750a81b895f35c3adb843cca46f0530f79fc1babb23789dc"}, ] -[[package]] -name = "snuggs" -version = "1.4.7" -description = "Snuggs are s-expressions for Numpy" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "snuggs-1.4.7-py3-none-any.whl", hash = "sha256:988dde5d4db88e9d71c99457404773dabcc7a1c45971bfbe81900999942d9f07"}, - {file = "snuggs-1.4.7.tar.gz", hash = "sha256:501cf113fe3892e14e2fee76da5cd0606b7e149c411c271898e6259ebde2617b"}, -] - -[package.dependencies] -numpy = "*" -pyparsing = ">=2.1.6" - -[package.extras] -test = ["hypothesis", "pytest"] - [[package]] name = "soupsieve" version = "2.7" @@ -4108,31 +3713,6 @@ pure-eval = "*" [package.extras] tests = ["cython", "littleutils", "pygments", "pytest", "typeguard"] -[[package]] -name = "supermercado" -version = "0.2.0" -description = "Supercharged mercantile" -optional = false -python-versions = "*" -groups = ["main"] -markers = "python_version >= \"3.12\"" -files = [ - {file = "supermercado-0.2.0-py3-none-any.whl", hash = "sha256:c3aab2a0992e324cee83653fb5166781bed92c35d29ae4181125d6a9da1bf222"}, - {file = "supermercado-0.2.0.tar.gz", hash = "sha256:639372b946c31d63196a8fc38dde7eafa4c28ba9472a7a754996eb43b9e8a69b"}, -] - -[package.dependencies] -affine = "*" -click = "*" -click-plugins = "*" -cligj = "*" -mercantile = "*" -numpy = "*" -rasterio = "*" - -[package.extras] -test = ["codecov", "pytest", "pytest-cov"] - [[package]] name = "tomli" version = "2.2.1" @@ -4239,7 +3819,6 @@ description = "Run-time type checker for Python" optional = false python-versions = ">=3.9" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "typeguard-4.4.3-py3-none-any.whl", hash = "sha256:7d8b4a3d280257fd1aa29023f22de64e29334bda0b172ff1040f05682223795e"}, {file = "typeguard-4.4.3.tar.gz", hash = "sha256:be72b9c85f322c20459b29060c5c099cd733d5886c4ee14297795e62b0c0d59b"}, @@ -4282,7 +3861,6 @@ description = "CLI interfaces & config objects, from types" optional = false python-versions = ">=3.8" groups = ["main"] -markers = "python_version < \"3.12\"" files = [ {file = "tyro-0.9.24-py3-none-any.whl", hash = "sha256:d8152e47375419752210da455226007b4bb9bd9c65af1de8fb12daf0658c91dc"}, {file = "tyro-0.9.24.tar.gz", hash = "sha256:5a9ef93d1b8e93cff2c5d82789a571d905d152e92af82a3ec96a17d668194df3"}, @@ -4486,5 +4064,5 @@ files = [ [metadata] lock-version = "2.1" -python-versions = ">=3.10" -content-hash = "a907090213deaf58df2c78c0680b0590577200313d1354e88c807cd6d43076e8" +python-versions = ">=3.10,<3.13" +content-hash = "18a2f7863ccb1c5fe159a15206a14f392c08bdedfa78efbafbe93feef36552f9" diff --git a/pymapgis/settings.py b/pymapgis/settings.py new file mode 100644 index 0000000..5d337b8 --- /dev/null +++ b/pymapgis/settings.py @@ -0,0 +1,11 @@ +from pydantic_settings import BaseSettings, SettingsConfigDict + + +class _Settings(BaseSettings): + cache_dir: str = "~/.cache/pymapgis" + default_crs: str = "EPSG:4326" + + model_config = SettingsConfigDict(env_prefix="PYMAPGIS_", extra="ignore") + + +settings = _Settings() diff --git a/pyproject.toml b/pyproject.toml index d98e8c5..df8aa54 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -21,6 +21,7 @@ requires = ["poetry-core>=2.0.0,<3.0.0"] build-backend = "poetry.core.masonry.api" [tool.poetry.dependencies] +python = ">=3.10,<3.13" [tool.poetry.group.dev.dependencies] pytest = "^8.4.0" diff --git a/tests/test_settings.py b/tests/test_settings.py new file mode 100644 index 0000000..1799c3d --- /dev/null +++ b/tests/test_settings.py @@ -0,0 +1,5 @@ +from pymapgis.settings import settings + + +def test_defaults(): + assert settings.default_crs == "EPSG:4326"