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)