https://github.com/xarray-contrib/minimum-dependency-versions
Automated minimum dependency policy checks
https://github.com/xarray-contrib/minimum-dependency-versions
Last synced: 4 months ago
JSON representation
Automated minimum dependency policy checks
- Host: GitHub
- URL: https://github.com/xarray-contrib/minimum-dependency-versions
- Owner: xarray-contrib
- License: other
- Created: 2024-11-11T10:52:48.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-09-10T15:13:31.000Z (6 months ago)
- Last Synced: 2025-10-05T22:49:10.109Z (5 months ago)
- Language: Python
- Homepage:
- Size: 34.2 KB
- Stars: 2
- Watchers: 10
- Forks: 2
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# minimum-dependency-versions
Check that the minimum dependency versions follow `xarray`'s policy.
## Usage
To use the `minimum-dependency-versions` action in workflows, create a policy file (`policy.yaml`):
```yaml
channels:
- conda-forge
platforms:
- noarch
- linux-64
policy:
# policy in months
# Example is xarray's values
packages:
python: 30
numpy: 18
default: 12
overrides:
# override the policy for specific packages
package3: 0.3.1
# these packages are completely ignored
exclude:
- package1
- package2
- ...
# these packages don't fail the CI, but will be printed in the report as a warning
ignored_violations:
- package4
```
If there are no packages with `overrides`, `exclude`, or `ignored_violations`, you can set
them to an empty mapping or sequence, respectively:
```yaml
...
overrides: {}
exclude: []
ignored_violations: []
```
Then add a new step to CI:
```yaml
jobs:
my-job:
...
steps:
...
- uses: xarray-contrib/minimum-dependency-versions@version
with:
policy: policy.yaml
environment-paths: path/to/env.yaml
```
To analyze multiple environments at the same time, pass a multi-line string:
```yaml
jobs:
my-job:
...
steps:
...
- uses: xarray-contrib/minimum-dependency-versions@version
with:
environment-paths: |
path/to/env1.yaml
path/to/env2.yaml
path/to/env3.yaml
```