From bd79a505dbf6f3ef7b844e41d50aa436d4e67e9d Mon Sep 17 00:00:00 2001 From: Jim Bosch Date: Fri, 17 Nov 2023 17:10:08 -0500 Subject: [PATCH] fixup! Stop ignoring unrecognized kwargs in DimensionRecord.__init__. --- python/lsst/daf/butler/dimensions/_records.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/python/lsst/daf/butler/dimensions/_records.py b/python/lsst/daf/butler/dimensions/_records.py index 60e52ea0a8..fd4614c0f1 100644 --- a/python/lsst/daf/butler/dimensions/_records.py +++ b/python/lsst/daf/butler/dimensions/_records.py @@ -296,6 +296,8 @@ def __init__(self, **kwargs: Any): # Note that we remove from kwargs as we go, to make sure there's # nothing left at the end. object.__setattr__(self, name, kwargs.pop(name, None)) + # Support 'datetime_begin' and 'datetime_end' instead of 'timespan' for + # backwards compatibility, but if one is provided both must be. if self.definition.temporal is not None and self.timespan is None and "datetime_begin" in kwargs: object.__setattr__( self,