From c8062bd2370a5361f0cce6fb3f8721a284281c76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adri=C3=A0=20Arrufat?= Date: Tue, 15 Sep 2026 10:20:36 +0200 Subject: [PATCH] Describe the async constructor arguments once instead of per argument The generated API reference repeated "Forwarded to the sync class" as a five-bullet Args section for AsyncCDPServer and AsyncBiDiServer, and five more times for AsyncBrowser. Review feedback on the docs site asked for either real descriptions or no bullets at all. The shared async server base now says it once in prose. AsyncBrowser keeps its Args section for max_concurrency, the only argument it does not forward, and names the forwarded ones in a sentence above it. Also drop "Prepare the facade" from both constructor summaries, which put an internal word for these wrappers on a public reference page. --- lightpanda/_serve.py | 9 ++------- lightpanda/async_browser.py | 10 ++++------ 2 files changed, 6 insertions(+), 13 deletions(-) diff --git a/lightpanda/_serve.py b/lightpanda/_serve.py index c5ba80c..39e6cdd 100644 --- a/lightpanda/_serve.py +++ b/lightpanda/_serve.py @@ -108,14 +108,9 @@ def __init__( args: Sequence[str] = (), port: int | None = None, ): - """Prepare the facade; the process is spawned by :meth:`start`. + """Store the settings; the process is spawned by :meth:`start`. - Args: - binary: Forwarded to the sync class. - env: Forwarded to the sync class. - verbose: Forwarded to the sync class. - args: Forwarded to the sync class. - port: Forwarded to the sync class. + Arguments are forwarded to the sync class. """ self._kwargs = dict(binary=binary, env=env, verbose=verbose, args=args, port=port) self._server: _S | None = None diff --git a/lightpanda/async_browser.py b/lightpanda/async_browser.py index 5909560..3b45fb5 100644 --- a/lightpanda/async_browser.py +++ b/lightpanda/async_browser.py @@ -85,14 +85,12 @@ def __init__( args: Sequence[str] = (), max_concurrency: int = 32, ): - """Prepare the facade; the process is spawned by :meth:`start`. + """Store the settings; the process is spawned by :meth:`start`. + + ``binary``, ``env``, ``timeout``, ``verbose`` and ``args`` are + forwarded to :class:`Browser`. Args: - binary: Forwarded to :class:`Browser`. - env: Forwarded to :class:`Browser`. - timeout: Forwarded to :class:`Browser`. - verbose: Forwarded to :class:`Browser`. - args: Forwarded to :class:`Browser`. max_concurrency: Caps the tool calls executing concurrently across this browser's sessions; worker threads are created lazily.