Skip to content

Commit c376a71

Browse files
committed
gh-135056: Document directory and custom_headers as keyword args.
1 parent 5f1fb94 commit c376a71

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

Doc/library/http.server.rst

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -369,15 +369,16 @@ instantiation, of which this module provides three different variants:
369369
mapping the directory structure to HTTP requests.
370370

371371
.. versionchanged:: 3.7
372-
Added the *directory* parameter.
372+
Added the *directory* keyword argument.
373373

374374
.. versionchanged:: 3.9
375-
The *directory* parameter accepts a :term:`path-like object`.
375+
The *directory* keyword argument accepts a :term:`path-like object`.
376376

377377
.. versionchanged:: next
378-
Added *response_headers*, which accepts an optional iterable of
379-
name/value pairs of HTTP headers to add to each successful HTTP status 200
380-
response. All other status code responses will not include these headers.
378+
Added a *response_headers* keyword argument, which accepts an optional
379+
iterable of name/value pairs of HTTP headers to add to each successful
380+
HTTP status 200 response. All other status code responses will not include
381+
these headers.
381382

382383
A lot of the work, such as parsing the request, is done by the base class
383384
:class:`BaseHTTPRequestHandler`. This class implements the :func:`do_GET`

0 commit comments

Comments
 (0)