Skip to content

Commit

Permalink
Prep new release (#439)
Browse files Browse the repository at this point in the history
* Prep changelog

* Bump to v2.2.0

* Remove unneeded var

* Fix links in CHANGELOG + add reminder in contributing guide

* Typo

* English
  • Loading branch information
sverhoeven committed Jul 8, 2024
1 parent 01564ee commit b4e0d16
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 2.1.1
current_version = 2.2.0

[bumpversion:file:src/ewatercycle/version.py]
search = __version__ = "{current_version}"
Expand Down
7 changes: 5 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,16 @@ Formatted as described on [https://keepachangelog.com](https://keepachangelog.co

## [Unreleased]

### [2.2.0] (2024-07-08)

### Added
- `ewatercycle.esmvaltool.search.search_esgf` can now be used to find climate model ensembles on ESGF that have the required input variables for generating forcing data ([#422](https://github.com/eWaterCycle/ewatercycle/pull/422)).
- `ewatercycle.observation.caravan.get_caravan_data()` ([#432](https://github.com/eWaterCycle/ewatercycle/issues/432))

### Fixed

- `get_usgs_data()` throws error ([#414](https://github.com/eWaterCycle/ewatercycle/issues/414))
- `get_usgs_data()` and 1get_grdc_data()` both return xarray.Dataset ([#253](https://github.com/eWaterCycle/ewatercycle/issues/253))
- `get_usgs_data()` and `get_grdc_data()` both return xarray.Dataset ([#253](https://github.com/eWaterCycle/ewatercycle/issues/253))

### Removed

Expand Down Expand Up @@ -248,7 +250,8 @@ Everthing listed at [2.0.0](2.0.0), but without the adding models part.
- Empty Python project directory structure
- Added symlink based data files copier

[Unreleased]: https://github.com/eWaterCycle/ewatercycle/compare/2.1.1...HEAD
[Unreleased]: https://github.com/eWaterCycle/ewatercycle/compare/2.2.0...HEAD
[2.2.0]: https://github.com/eWaterCycle/ewatercycle/compare/2.1.1...2.2.0
[2.1.1]: https://github.com/eWaterCycle/ewatercycle/compare/2.1.0...2.1.1
[2.1.0]: https://github.com/eWaterCycle/ewatercycle/compare/2.0.0...2.1.0
[2.0.0]: https://github.com/eWaterCycle/ewatercycle/compare/2.0.0b2...2.0.0
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ This section is for maintainers of the package.
1. Checkout ``HEAD`` of ``main`` branch with ``git checkout main`` and ``git pull``.
2. Determine what new version (major, minor or patch) to use. Package uses `semantic versioning <https://semver.org>`_.
3. Run ``bump2version <major|minor|patch>`` to update version in package files.
4. Update CHANGELOG.md with changes between current and new version.
4. Update CHANGELOG.md with changes between current and new version. (Don't forget to also update the links at the bottom of the file)
5. Make sure pre-commit hooks are green for all files by running ``pre-commit run --all-files``.
6. Commit & push changes to GitHub.
7. Wait for [GitHub
Expand Down
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@
#
# The short X.Y version.
# The full version, including alpha/beta/rc tags.
version = "2.1.1"
version = "2.2.0"
release = version

# The language for content autogenerated by Sphinx. Refer to documentation
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = ewatercycle
version = 2.1.1
version = 2.2.0
description = A Python package for running and validating a hydrology model
long_description = file: README.md
long_description_content_type = text/markdown
Expand Down
4 changes: 1 addition & 3 deletions src/ewatercycle/observation/grdc.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,6 @@ def get_grdc_data(

# Read the NetCDF file
nc_file = data_path / "GRDC-Daily.nc"
station_not_in_nc = False
if nc_file.exists():
ds = xr.open_dataset(nc_file)
if int(station_id) in ds["id"]:
Expand All @@ -110,12 +109,11 @@ def get_grdc_data(
time=slice(get_time(start_time).date(), get_time(end_time).date()),
)
return ds.rename({"runoff_mean": column})
station_not_in_nc = True

# Read the text data
raw_file = data_path / f"{station_id}_Q_Day.Cmd.txt"
if not raw_file.exists():
if nc_file.exists() and station_not_in_nc:
if nc_file.exists():
raise ValueError(
f"The grdc station {station_id} is not in the {nc_file} file and {raw_file} does not exist!" # noqa: E501
)
Expand Down
2 changes: 1 addition & 1 deletion src/ewatercycle/version.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""Version of ewatercycle package."""
__version__ = "2.1.1"
__version__ = "2.2.0"

0 comments on commit b4e0d16

Please sign in to comment.