Skip to content

Commit 1705fb1

Browse files
committedDec 17, 2024·
better formatting of YAML, synchronize dependencies
1 parent a55a3aa commit 1705fb1

File tree

8 files changed

+145
-115
lines changed

8 files changed

+145
-115
lines changed
 

‎.codacy.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
22
engines:
3-
pylint:
4-
enabled: true
5-
python_version: 3
3+
pylint:
4+
enabled: true
5+
python_version: 3
66
exclude_paths:
77
- 'tests/**'
88
- 'docs/source/conf.py'

‎.github/workflows/main.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,8 @@ jobs:
4444
run:
4545
shell: bash -l {0}
4646
strategy:
47-
matrix:
48-
python-version: [ "3.10", "3.11", "3.12"]
47+
matrix:
48+
python-version: [ "3.10", "3.11", "3.12" ]
4949
steps:
5050
- name: Harden Runner
5151
uses: step-security/harden-runner@0080882f6c36860b6ba35c610c98ce87d4e2f26f # v2.10.2

‎.readthedocs.yml

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,12 +13,12 @@ sphinx:
1313
fail_on_warning: false
1414

1515
# Optionally build your docs in additional formats such as PDF and ePub
16-
formats: []
16+
formats: [ ]
1717

1818
build:
19-
os: ubuntu-22.04
19+
os: ubuntu-lts-latest
2020
tools:
21-
python: "mambaforge-22.9"
21+
python: "mambaforge-latest"
2222

2323
conda:
2424
environment: environment-docs.yml

‎.yamllint.yaml

+32-1
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,39 @@
11
---
22

33
rules:
4+
5+
brackets:
6+
forbid: false
7+
min-spaces-inside: 1
8+
max-spaces-inside: 1
9+
10+
commas:
11+
min-spaces-after: 1
12+
413
document-start: disable
14+
15+
float-values:
16+
require-numeral-before-decimal: true
17+
18+
hyphens:
19+
max-spaces-after: 1
20+
21+
indentation:
22+
indent-sequences: whatever
23+
spaces: consistent
24+
25+
key-duplicates:
26+
forbid-duplicated-merge-keys: true
27+
528
line-length:
6-
max: 120
29+
allow-non-breakable-words: true
30+
allow-non-breakable-inline-mappings: true
31+
max: 140
732
level: warning
33+
34+
new-lines:
35+
type: unix
36+
37+
trailing-spaces: {}
38+
839
truthy: disable

‎environment-docs.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ dependencies:
1313
- sphinx >=7.0.0
1414
- sphinxcontrib-bibtex >=2.6.0
1515
- xarray >=2023.01.0,<2023.11.0
16-
- xclim =0.43 # remember to match xclim version in requirements_docs.txt as well
16+
- xclim ==0.52.2 # remember to match xclim version in requirements_docs.txt as well

‎environment.yml

+1-2
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ name: finch
22
channels:
33
- conda-forge
44
dependencies:
5-
- python >=3.9,<3.13
5+
- python >=3.10,<3.13
66
- pip >=24.2.0
77
- anyascii >=0.3.0
88
- cftime >=1.4.1
@@ -12,7 +12,6 @@ dependencies:
1212
- dask >=2023.5.1
1313
- distributed
1414
- geopandas !=0.13.1
15-
- h5netcdf
1615
- netcdf4 <=1.6.5
1716
- numpy >=1.23.0
1817
- pandas >=2.2.0

‎finch/datasets.yml

+62-62
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@ candcs-u5:
66
suffix: "*.nc"
77
pattern: "{variable}_{frequency}_BCCAQv2+ANUSPLIN300_{model}_{scenario}_{realization}_{date_start}-{date_end}.nc"
88
allowed_values:
9-
scenario: [rcp26, rcp45, rcp85]
10-
variable: [tasmin, tasmax, pr]
9+
scenario: [ rcp26, rcp45, rcp85 ]
10+
variable: [ tasmin, tasmax, pr ]
1111
model:
1212
&u5models
1313
- BNU-ESM
@@ -39,18 +39,18 @@ candcs-u5:
3939
24models: *u5models
4040
pcic12:
4141
# taken from: https://www.pacificclimate.org/data/statistically-downscaled-climate-scenarios
42-
- [ ACCESS1-0 , r1i1p1 ]
43-
- [ CCSM4 , r2i1p1 ]
44-
- [ CNRM-CM5 , r1i1p1 ]
45-
- [ CSIRO-Mk3-6-0 , r1i1p1 ]
46-
- [ CanESM2 , r1i1p1 ]
47-
- [ GFDL-ESM2G , r1i1p1 ]
48-
- [ HadGEM2-CC , r1i1p1 ]
49-
- [ HadGEM2-ES , r1i1p1 ]
50-
- [ MIROC5 , r3i1p1 ]
51-
- [ MPI-ESM-LR , r3i1p1 ]
52-
- [ MRI-CGCM3 , r1i1p1 ]
53-
- [ inmcm4 , r1i1p1 ]
42+
- [ ACCESS1-0, r1i1p1 ]
43+
- [ CCSM4, r2i1p1 ]
44+
- [ CNRM-CM5, r1i1p1 ]
45+
- [ CSIRO-Mk3-6-0, r1i1p1 ]
46+
- [ CanESM2, r1i1p1 ]
47+
- [ GFDL-ESM2G, r1i1p1 ]
48+
- [ HadGEM2-CC, r1i1p1 ]
49+
- [ HadGEM2-ES, r1i1p1 ]
50+
- [ MIROC5, r3i1p1 ]
51+
- [ MPI-ESM-LR, r3i1p1 ]
52+
- [ MRI-CGCM3, r1i1p1 ]
53+
- [ inmcm4, r1i1p1 ]
5454

5555
# This is a copy of the above for backward compatibility reasons.
5656
bccaqv2: *candcsu5
@@ -62,7 +62,7 @@ candcs-u6:
6262
pattern: "{variable}_{frequency}_BCCAQv2+ANUSPLIN300_{model}_{scenario}_{realization}_{}_{date_start}-{date_end}.nc"
6363
allowed_values:
6464
scenario: [ ssp126, ssp245, ssp585 ]
65-
variable: [ tasmin, tasmax, pr]
65+
variable: [ tasmin, tasmax, pr ]
6666
model:
6767
- ACCESS-CM2
6868
- ACCESS-ESM1-5
@@ -92,61 +92,61 @@ candcs-u6:
9292
- UKESM1-0-LL
9393
model_lists:
9494
26models:
95-
- ACCESS-CM2
96-
- ACCESS-ESM1-5
97-
- BCC-CSM2-MR
98-
- CMCC-ESM2
99-
- CNRM-CM6-1
100-
- CNRM-ESM2-1
101-
- CanESM5
102-
- [EC-Earth3, r4i1p1f1]
103-
- EC-Earth3-Veg
104-
- FGOALS-g3
105-
- GFDL-ESM4
106-
- HadGEM3-GC31-LL
107-
- INM-CM4-8
108-
- INM-CM5-0
109-
- IPSL-CM6A-LR
110-
- [KACE-1-0-G, r2i1p1f1]
111-
- KIOST-ESM
112-
- MIROC-ES2L
113-
- MIROC6
114-
- MPI-ESM1-2-HR
115-
- MPI-ESM1-2-LR
116-
- MRI-ESM2-0
117-
- NorESM2-LM
118-
- NorESM2-MM
119-
- TaiESM1
120-
- UKESM1-0-LL
95+
- ACCESS-CM2
96+
- ACCESS-ESM1-5
97+
- BCC-CSM2-MR
98+
- CMCC-ESM2
99+
- CNRM-CM6-1
100+
- CNRM-ESM2-1
101+
- CanESM5
102+
- [ EC-Earth3, r4i1p1f1 ]
103+
- EC-Earth3-Veg
104+
- FGOALS-g3
105+
- GFDL-ESM4
106+
- HadGEM3-GC31-LL
107+
- INM-CM4-8
108+
- INM-CM5-0
109+
- IPSL-CM6A-LR
110+
- [ KACE-1-0-G, r2i1p1f1 ]
111+
- KIOST-ESM
112+
- MIROC-ES2L
113+
- MIROC6
114+
- MPI-ESM1-2-HR
115+
- MPI-ESM1-2-LR
116+
- MRI-ESM2-0
117+
- NorESM2-LM
118+
- NorESM2-MM
119+
- TaiESM1
120+
- UKESM1-0-LL
121121

122122
humidex-daily:
123123
local: false
124124
depth: 1
125125
path: https://pavics.ouranos.ca/twitcher/ows/proxy/thredds/catalog/birdhouse/eccc/CCCS_humidex/Humidex/daily/catalog.html
126126
pattern: "{variable}_MBCn_ERA5-Land_{model}_{scenario}_{realization}_{date_start}-{date_end}.nc"
127127
allowed_values:
128-
scenario: [ssp126, ssp245, ssp585]
129-
variable: [HXmax]
128+
scenario: [ ssp126, ssp245, ssp585 ]
129+
variable: [ HXmax ]
130130
model:
131131
&hxmax_day_models
132-
- MPI-ESM1-2-HR
133-
- EC-Earth3
134-
- ACCESS-CM2
135-
- MIROC-ES2L
136-
- EC-Earth3-Veg
137-
- IPSL-CM6A-LR
138-
- INM-CM5-0
139-
- FGOALS-g3
140-
- CanESM5
141-
- MIROC6
142-
- GISS-E2-1-G
143-
- EC-Earth3-Veg-LR
144-
- CNRM-ESM2-1
145-
- MPI-ESM1-2-LR
146-
- INM-CM4-8
147-
- MRI-ESM2-0
148-
- CMCC-ESM2
149-
- ACCESS-ESM1-5
150-
- CNRM-CM6-1
132+
- MPI-ESM1-2-HR
133+
- EC-Earth3
134+
- ACCESS-CM2
135+
- MIROC-ES2L
136+
- EC-Earth3-Veg
137+
- IPSL-CM6A-LR
138+
- INM-CM5-0
139+
- FGOALS-g3
140+
- CanESM5
141+
- MIROC6
142+
- GISS-E2-1-G
143+
- EC-Earth3-Veg-LR
144+
- CNRM-ESM2-1
145+
- MPI-ESM1-2-LR
146+
- INM-CM4-8
147+
- MRI-ESM2-0
148+
- CMCC-ESM2
149+
- ACCESS-ESM1-5
150+
- CNRM-CM6-1
151151
model_lists:
152152
humidex_models: *hxmax_day_models

‎tests/test_data.yml

+41-41
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ test_single_cell:
55
suffix: "*.nc"
66
pattern: "{variable}_{frequency}_BCCAQv2+ANUSPLIN300_{model}_{scenario}_{realization}_{date_start}-{date_end}.nc"
77
allowed_values:
8-
scenario: [rcp26, rcp45, rcp85]
9-
variable: [tasmin, tasmax, pr]
8+
scenario: [ rcp26, rcp45, rcp85 ]
9+
variable: [ tasmin, tasmax, pr ]
1010
model:
1111
&u5models
1212
- BNU-ESM
@@ -37,19 +37,19 @@ test_single_cell:
3737
# The absence of realization specification implies r1 is taken.
3838
24models: *u5models
3939
pcic12:
40-
# taken from: https://www.pacificclimate.org/data/statistically-downscaled-climate-scenarios
41-
- [ ACCESS1-0 , r1i1p1 ]
42-
- [ CCSM4 , r2i1p1 ]
43-
- [ CNRM-CM5 , r1i1p1 ]
44-
- [ CSIRO-Mk3-6-0 , r1i1p1 ]
45-
- [ CanESM2 , r1i1p1 ]
46-
- [ GFDL-ESM2G , r1i1p1 ]
47-
- [ HadGEM2-CC , r1i1p1 ]
48-
- [ HadGEM2-ES , r1i1p1 ]
49-
- [ MIROC5 , r3i1p1 ]
50-
- [ MPI-ESM-LR , r3i1p1 ]
51-
- [ MRI-CGCM3 , r1i1p1 ]
52-
- [ inmcm4 , r1i1p1 ]
40+
# taken from: https://www.pacificclimate.org/data/statistically-downscaled-climate-scenarios
41+
- [ ACCESS1-0, r1i1p1 ]
42+
- [ CCSM4, r2i1p1 ]
43+
- [ CNRM-CM5, r1i1p1 ]
44+
- [ CSIRO-Mk3-6-0, r1i1p1 ]
45+
- [ CanESM2, r1i1p1 ]
46+
- [ GFDL-ESM2G, r1i1p1 ]
47+
- [ HadGEM2-CC, r1i1p1 ]
48+
- [ HadGEM2-ES, r1i1p1 ]
49+
- [ MIROC5, r3i1p1 ]
50+
- [ MPI-ESM-LR, r3i1p1 ]
51+
- [ MRI-CGCM3, r1i1p1 ]
52+
- [ inmcm4, r1i1p1 ]
5353

5454
test_subset:
5555
local: true
@@ -58,8 +58,8 @@ test_subset:
5858
suffix: "*.nc"
5959
pattern: "{variable}_{model}_{scenario}_subset.nc"
6060
allowed_values:
61-
scenario: [rcp26, rcp45]
62-
variable: [tasmin, tasmax]
61+
scenario: [ rcp26, rcp45 ]
62+
variable: [ tasmin, tasmax ]
6363
model:
6464
- inmcm4
6565
- bcc-csm1-1
@@ -72,28 +72,28 @@ test_humidex:
7272
suffix: "*.nc"
7373
pattern: "{variable}_MBCn_ERA5-Land_{model}_{scenario}_{realization}_{date_start}-{date_end}_sub.nc"
7474
allowed_values:
75-
scenario: [ssp245, ssp585 ]
76-
variable: [ HXmax ]
77-
model:
78-
&hxmax_day_sub
79-
- MPI-ESM1-2-HR
80-
- EC-Earth3
81-
- ACCESS-CM2
82-
- MIROC-ES2L
83-
- EC-Earth3-Veg
84-
- IPSL-CM6A-LR
85-
- INM-CM5-0
86-
- FGOALS-g3
87-
- CanESM5
88-
- MIROC6
89-
- GISS-E2-1-G
90-
- EC-Earth3-Veg-LR
91-
- CNRM-ESM2-1
92-
- MPI-ESM1-2-LR
93-
- INM-CM4-8
94-
- MRI-ESM2-0
95-
- CMCC-ESM2
96-
- ACCESS-ESM1-5
97-
- CNRM-CM6-1
75+
scenario: [ ssp245, ssp585 ]
76+
variable: [ HXmax ]
77+
model:
78+
&hxmax_day_sub
79+
- MPI-ESM1-2-HR
80+
- EC-Earth3
81+
- ACCESS-CM2
82+
- MIROC-ES2L
83+
- EC-Earth3-Veg
84+
- IPSL-CM6A-LR
85+
- INM-CM5-0
86+
- FGOALS-g3
87+
- CanESM5
88+
- MIROC6
89+
- GISS-E2-1-G
90+
- EC-Earth3-Veg-LR
91+
- CNRM-ESM2-1
92+
- MPI-ESM1-2-LR
93+
- INM-CM4-8
94+
- MRI-ESM2-0
95+
- CMCC-ESM2
96+
- ACCESS-ESM1-5
97+
- CNRM-CM6-1
9898
model_lists:
99-
humidex_submods: *hxmax_day_sub
99+
humidex_submods: *hxmax_day_sub

0 commit comments

Comments
 (0)
Please sign in to comment.