Remove unnecessary spaces in code blocks in urllib.parse.rst (GH-21500)
This should also fix the syntax highlighting for these code blocks Automerge-Triggered-By: @csabella
This commit is contained in:
parent
d4d127f1c6
commit
5e5c0f9866
|
@ -68,15 +68,15 @@ or on combining URL components into a URL string.
|
|||
.. doctest::
|
||||
:options: +NORMALIZE_WHITESPACE
|
||||
|
||||
>>> from urllib.parse import urlparse
|
||||
>>> urlparse('//www.cwi.nl:80/%7Eguido/Python.html')
|
||||
ParseResult(scheme='', netloc='www.cwi.nl:80', path='/%7Eguido/Python.html',
|
||||
>>> from urllib.parse import urlparse
|
||||
>>> urlparse('//www.cwi.nl:80/%7Eguido/Python.html')
|
||||
ParseResult(scheme='', netloc='www.cwi.nl:80', path='/%7Eguido/Python.html',
|
||||
params='', query='', fragment='')
|
||||
>>> urlparse('www.cwi.nl/%7Eguido/Python.html')
|
||||
ParseResult(scheme='', netloc='', path='www.cwi.nl/%7Eguido/Python.html',
|
||||
>>> urlparse('www.cwi.nl/%7Eguido/Python.html')
|
||||
ParseResult(scheme='', netloc='', path='www.cwi.nl/%7Eguido/Python.html',
|
||||
params='', query='', fragment='')
|
||||
>>> urlparse('help/Python.html')
|
||||
ParseResult(scheme='', netloc='', path='help/Python.html', params='',
|
||||
>>> urlparse('help/Python.html')
|
||||
ParseResult(scheme='', netloc='', path='help/Python.html', params='',
|
||||
query='', fragment='')
|
||||
|
||||
The *scheme* argument gives the default addressing scheme, to be
|
||||
|
@ -138,14 +138,14 @@ or on combining URL components into a URL string.
|
|||
.. doctest::
|
||||
:options: +NORMALIZE_WHITESPACE
|
||||
|
||||
>>> from urllib.parse import urlparse
|
||||
>>> u = urlparse('//www.cwi.nl:80/%7Eguido/Python.html')
|
||||
>>> u
|
||||
ParseResult(scheme='', netloc='www.cwi.nl:80', path='/%7Eguido/Python.html',
|
||||
params='', query='', fragment='')
|
||||
>>> u._replace(scheme='http')
|
||||
ParseResult(scheme='http', netloc='www.cwi.nl:80', path='/%7Eguido/Python.html',
|
||||
params='', query='', fragment='')
|
||||
>>> from urllib.parse import urlparse
|
||||
>>> u = urlparse('//www.cwi.nl:80/%7Eguido/Python.html')
|
||||
>>> u
|
||||
ParseResult(scheme='', netloc='www.cwi.nl:80', path='/%7Eguido/Python.html',
|
||||
params='', query='', fragment='')
|
||||
>>> u._replace(scheme='http')
|
||||
ParseResult(scheme='http', netloc='www.cwi.nl:80', path='/%7Eguido/Python.html',
|
||||
params='', query='', fragment='')
|
||||
|
||||
|
||||
.. versionchanged:: 3.2
|
||||
|
|
Loading…
Reference in New Issue