From e2c3f1317aa7f188f1e7d767ea93553719648f91 Mon Sep 17 00:00:00 2001 From: "David H. Irving" Date: Wed, 3 Jan 2024 09:49:23 -0700 Subject: [PATCH] Improve DirectButler documentation --- python/lsst/daf/butler/direct_butler.py | 14 +++++++++++--- python/lsst/daf/butler/remote_butler/_factory.py | 1 - 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/python/lsst/daf/butler/direct_butler.py b/python/lsst/daf/butler/direct_butler.py index d9ce6b216e..be41e97551 100644 --- a/python/lsst/daf/butler/direct_butler.py +++ b/python/lsst/daf/butler/direct_butler.py @@ -126,9 +126,8 @@ class DirectButler(Butler): # numpydoc ignore=PR02 Notes ----- - Most users should call `DirectButler`.``create_from_config`` or the - top-level `Butler`.``from_config`` instead of using this constructor - directly. + Most users should call the top-level `Butler`.``from_config`` instead of + using this constructor directly. """ # This is __new__ instead of __init__ because we have to support @@ -182,6 +181,11 @@ def create_from_config( without_datastore : `bool`, optional If `True` do not attach a datastore to this butler. Any attempts to use a datastore will fail. + + Notes + ----- + Most users should call the top-level `Butler`.``from_config`` + instead of using this function directly. """ if "run" in config or "collection" in config: raise ValueError("Passing a run or collection via configuration is no longer supported.") @@ -2361,6 +2365,7 @@ def _query_dimension_records( return data_ids _config: ButlerConfig + """Configuration for this Butler instance.""" _registry: SqlRegistry """The object that manages dataset metadata and relationships @@ -2384,3 +2389,6 @@ def _query_dimension_records( """ _registry_shim: RegistryShim + """Shim object to provide a legacy public interface for querying via the + the ``registry`` property. + """ diff --git a/python/lsst/daf/butler/remote_butler/_factory.py b/python/lsst/daf/butler/remote_butler/_factory.py index 64ff112f6c..a807230bed 100644 --- a/python/lsst/daf/butler/remote_butler/_factory.py +++ b/python/lsst/daf/butler/remote_butler/_factory.py @@ -49,7 +49,6 @@ class RemoteButlerFactory: server_url : `str` The URL of the Butler server that RemoteButler instances created by this factory will connect to. - http_client : `httpx.Client`, optional The httpx connection pool that RemoteButler instances created by this factory will use for making HTTP requests. If omitted, creates a new