From e9c000e8ee0823fe99d89433f711ca467b530c4c Mon Sep 17 00:00:00 2001 From: Jiwoo Lee Date: Sat, 21 Sep 2024 19:40:57 -0700 Subject: [PATCH] to ensure year to be int --- xcdat/temporal.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/xcdat/temporal.py b/xcdat/temporal.py index ecb373c4..9b27d7d3 100644 --- a/xcdat/temporal.py +++ b/xcdat/temporal.py @@ -1085,9 +1085,9 @@ def _drop_incomplete_djf(self, dataset: xr.Dataset) -> xr.Dataset: ds[self.dim].dt.year.values[-1], ) incomplete_seasons = ( - f"{start_year:04d}-01", - f"{start_year:04d}-02", - f"{end_year:04d}-12", + f"{int(start_year):04d}-01", + f"{int(start_year):04d}-02", + f"{int(end_year):04d}-12", ) for year_month in incomplete_seasons: