@@ -138,14 +138,13 @@ The following classes are provided:
138138
139139 *url * should be a string containing a valid URL.
140140
141- *data * may be a string specifying additional data to send to the
142- server, or ``None `` if no such data is needed. Currently HTTP
143- requests are the only ones that use *data *, in order to choose between
144- ``'GET' `` and ``'POST' `` when *method * is not specified.
145- *data * should be a buffer in the standard
146- :mimetype: `application/x-www-form-urlencoded ` format. The
147- :func: `urllib.parse.urlencode ` function takes a mapping or sequence
148- of 2-tuples and returns a string in this format.
141+ *data * may be a bytes object specifying additional data to send to the
142+ server, or ``None `` if no such data is needed. Currently HTTP requests are
143+ the only ones that use *data *; the HTTP request will be a POST instead of a
144+ GET when the *data * parameter is provided. *data * should be a buffer in the
145+ standard :mimetype: `application/x-www-form-urlencoded ` format. The
146+ :func: `urllib.parse.urlencode ` function takes a mapping or sequence of
147+ 2-tuples and returns a string in this format.
149148
150149 *headers * should be a dictionary, and will be treated as if
151150 :meth: `add_header ` was called with each key and value as arguments.
@@ -1183,7 +1182,7 @@ some point in the future.
11831182
11841183 If the *url * uses the :file: `http: ` scheme identifier, the optional *data *
11851184 argument may be given to specify a ``POST `` request (normally the request
1186- type is ``GET ``). The *data * argument must in standard
1185+ type is ``GET ``). The *data * argument must be a bytes object in standard
11871186 :mimetype: `application/x-www-form-urlencoded ` format; see the
11881187 :func: `urlencode ` function below.
11891188
0 commit comments