@@ -206,23 +206,53 @@ def _log_once(self, level: int, message: str, *args: object, **kwargs: object) -
206206 self ._logger .log (level , message , * args , ** kwargs )
207207
208208 def debug_once (self , message : str , * args : object , ** kwargs : object ) -> None :
209- """Log a ``DEBUG`` message once (deduplicated)."""
209+ """Log a ``DEBUG`` message once (deduplicated).
210+
211+ Args:
212+ message: Message value consumed by this operation.
213+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
214+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
215+ """
210216 self ._log_once (logging .DEBUG , message , * args , ** kwargs )
211217
212218 def info_once (self , message : str , * args : object , ** kwargs : object ) -> None :
213- """Log an ``INFO`` message once (deduplicated)."""
219+ """Log an ``INFO`` message once (deduplicated).
220+
221+ Args:
222+ message: Message value consumed by this operation.
223+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
224+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
225+ """
214226 self ._log_once (logging .INFO , message , * args , ** kwargs )
215227
216228 def warn_once (self , message : str , * args : object , ** kwargs : object ) -> None :
217- """Log a ``WARNING`` message once (deduplicated)."""
229+ """Log a ``WARNING`` message once (deduplicated).
230+
231+ Args:
232+ message: Message value consumed by this operation.
233+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
234+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
235+ """
218236 self ._log_once (logging .WARNING , message , * args , ** kwargs )
219237
220238 def warning_once (self , message : str , * args : object , ** kwargs : object ) -> None :
221- """Alias for :meth:`warn_once`."""
239+ """Alias for :meth:`warn_once`.
240+
241+ Args:
242+ message: Message value consumed by this operation.
243+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
244+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
245+ """
222246 self ._log_once (logging .WARNING , message , * args , ** kwargs )
223247
224248 def error_once (self , message : str , * args : object , ** kwargs : object ) -> None :
225- """Log an ``ERROR`` message once (deduplicated)."""
249+ """Log an ``ERROR`` message once (deduplicated).
250+
251+ Args:
252+ message: Message value consumed by this operation.
253+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
254+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
255+ """
226256 self ._log_once (logging .ERROR , message , * args , ** kwargs )
227257
228258 def clear_once_cache (self ) -> None :
@@ -251,7 +281,15 @@ def __getattr__(self, name: str) -> Callable[..., object]:
251281
252282 @wraps (getattr (logging .Logger , method_name ))
253283 def wrapped_log_method (* args : object , ** kwargs : object ) -> object :
254- """Delegate to the underlying logger method."""
284+ """Delegate to the underlying logger method.
285+
286+ Args:
287+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
288+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
289+
290+ Returns:
291+ Result described by this helper.
292+ """
255293 self ._ensure_initialized ()
256294 return getattr (self ._logger , method_name )(* args , ** kwargs )
257295
@@ -264,15 +302,31 @@ def wrapped_log_method(*args: object, **kwargs: object) -> object:
264302
265303 @wraps (getattr (logging .Logger , method_name ))
266304 def wrapped_log_method (* args : object , ** kwargs : object ) -> object :
267- """Delegate to the named level method of the underlying logger."""
305+ """Delegate to the named level method of the underlying logger.
306+
307+ Args:
308+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
309+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
310+
311+ Returns:
312+ Result described by this helper.
313+ """
268314 self ._ensure_initialized ()
269315 return getattr (self ._logger , method_name )(* args , ** kwargs )
270316
271317 return wrapped_log_method
272318
273319 @wraps (logging .Logger .log )
274320 def wrapped_log_method (* args : object , ** kwargs : object ) -> object :
275- """Log at the dynamically-resolved level."""
321+ """Log at the dynamically-resolved level.
322+
323+ Args:
324+ *args: Additional positional arguments forwarded to the wrapped callable or backend.
325+ **kwargs: Additional keyword arguments forwarded to the wrapped callable or backend.
326+
327+ Returns:
328+ Result described by this helper.
329+ """
276330 self ._ensure_initialized ()
277331 return self ._logger .log (level , * args , ** kwargs )
278332
@@ -424,7 +478,13 @@ def __enter__(self):
424478 return self
425479
426480 def __exit__ (self , exc_type , exc_val , exc_tb ):
427- """Context-manager exit — auto-completes if no exception was raised."""
481+ """Context-manager exit — auto-completes if no exception was raised.
482+
483+ Args:
484+ exc_type: Exc type value consumed by this operation.
485+ exc_val: Exc val value consumed by this operation.
486+ exc_tb: Exc tb value consumed by this operation.
487+ """
428488 if exc_type is None :
429489 self .complete ()
430490 return False
0 commit comments