From 57c89563b610b7925cc7730a9298e9dfa99104e5 Mon Sep 17 00:00:00 2001 From: Tim Jenness Date: Tue, 6 Aug 2024 17:23:39 -0700 Subject: [PATCH] Fix where the old day_obs import warning is issued from --- python/lsst/daf/butler/transfers/_yaml.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/python/lsst/daf/butler/transfers/_yaml.py b/python/lsst/daf/butler/transfers/_yaml.py index 64461f279e..f6c05e90ee 100644 --- a/python/lsst/daf/butler/transfers/_yaml.py +++ b/python/lsst/daf/butler/transfers/_yaml.py @@ -597,7 +597,8 @@ def __init__(self, stream: IO, registry: SqlRegistry): warnings.warn( "Constructing day_obs records with no timespans for " "visit/exposure records that were exported before day_obs was a dimension. " - f"(instrument{plural}: {missing_offsets})" + f"(instrument{plural}: {missing_offsets})", + stacklevel=find_outside_stacklevel("lsst.daf.butler"), ) # key is (dataset type name, run)