From c7be916dacc177dff11a08bd5e69a9a8238a2f83 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Fri, 17 Jan 2025 10:51:06 +0000 Subject: [PATCH] [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --- src/nc_time_axis/__init__.py | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/nc_time_axis/__init__.py b/src/nc_time_axis/__init__.py index 813be9b..8e47f9b 100644 --- a/src/nc_time_axis/__init__.py +++ b/src/nc_time_axis/__init__.py @@ -207,8 +207,7 @@ def __init__(self, locator, calendar, time_units=None): self.calendar = calendar if time_units is not None: warnings.warn( - "The time_units argument will be removed in nc_time_axis " - "version 1.5", + "The time_units argument will be removed in nc_time_axis version 1.5", DeprecationWarning, ) self.time_units = time_units @@ -298,14 +297,14 @@ def __init__(self, max_n_ticks, calendar, date_unit=None, min_n_ticks=3): self.calendar = calendar if date_unit is not None: warnings.warn( - "The date_unit argument will be removed in " "nc_time_axis version 1.5", + "The date_unit argument will be removed in nc_time_axis version 1.5", DeprecationWarning, ) self.date_unit = date_unit else: self.date_unit = _TIME_UNITS if not self.date_unit.lower().startswith("days since"): - emsg = "The date unit must be days since for a NetCDF " "time locator." + emsg = "The date unit must be days since for a NetCDF time locator." raise ValueError(emsg) self.resolution = _DEFAULT_RESOLUTION self._cached_resolution = {} @@ -480,7 +479,7 @@ def default_units(cls, sample_point, axis): else: # Deal with a single `sample_point` value. if not hasattr(sample_point, "calendar"): - msg = "Expecting cftimes with an extra " '"calendar" attribute.' + msg = 'Expecting cftimes with an extra "calendar" attribute.' raise ValueError(msg) calendar = sample_point.calendar date_type = type(sample_point)