Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Contributors: Trevor James Smith (:user:`Zeitsperre`).

Changes
^^^^^^^
* `raven-hydro` minimum version updated from v0.5.0 to v4.12.1 (for more information, see: https://github.com/Ouranosinc/raven-hydro/pull/93). (PR #587)
* Dependency updates. (PR #584):
* Updated required `xskillscore` (``>= 0.0.29``) and `climpred` (``>= 2.6.0``).
* Removed version pins on `intake` and `intake-xarray`.
Expand Down
2 changes: 1 addition & 1 deletion environment-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ channels:
- conda-forge
dependencies:
- python >=3.10,<3.15
- raven-hydro >=0.5.0,<1.0
- raven-hydro >=4.12.1,<5.0
# - libgcc # for mixing raven-hydro from PyPI with conda environments
- cftime >=1.4.1
- cf_xarray >=0.9.3
Expand Down
2 changes: 1 addition & 1 deletion environment-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ channels:
- conda-forge
dependencies:
- python >=3.13,<3.14
- raven-hydro >=0.5.0,<1.0
- raven-hydro >=4.12.1,<5.0
- cftime >=1.4.1
- cf-xarray >=0.9.3
- click >=8.2.0
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ gis = [
"shapely >=2.0"
]
raven-hydro = [
"raven-hydro >=0.5.0,<1.0"
"raven-hydro >=4.12.1,<5.0"
]
all = [
"ravenpy[dev]",
Expand Down
8 changes: 5 additions & 3 deletions src/ravenpy/config/rvs.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
from dataclasses import asdict, fields, is_dataclass
from pathlib import Path
from textwrap import dedent
from typing import Any, Optional, Union
from typing import Any, Optional, Union, cast

import cftime
from pydantic import ConfigDict, Field, ValidationInfo, field_validator
Expand Down Expand Up @@ -448,6 +448,8 @@ def is_symbolic(params: Union[dict, Any]) -> bool:
from pymbolic.primitives import Variable

if is_dataclass(params) and not isinstance(params, type):
params = {field.name: getattr(params, field.name) for field in fields(params)}
param_dict: dict = {field.name: getattr(params, field.name) for field in fields(params)}
else:
param_dict = cast(dict, params)

return any([isinstance(v, Variable) for v in params.values()])
return any([isinstance(v, Variable) for v in param_dict.values()])
Loading