[New-bugs-announce] [issue36064] docs: urllib.request.Request not accepting iterables data type

Lye report at bugs.python.org
Thu Feb 21 05:23:41 EST 2019


New submission from Lye <sylye at yahoo.com>:

I found out in the docs 3.6, in the class urllib.request.Request, for the input of 'data' data types, it says :

"The supported object types include bytes, file-like objects, and iterables."

But after testing it with data type dict for the 'data' input, I got error of:

"can't concat str to bytes"

It seems the docs should't say the 'data' data types support iterables.

There more detail discussion is at : https://stackoverflow.com/questions/54802272/some-fundamental-concept-used-in-python-docs

Hope this helps, thanks !

----------
assignee: docs at python
components: Documentation
messages: 336198
nosy: docs at python, sylye
priority: normal
severity: normal
status: open
title: docs: urllib.request.Request not accepting iterables data type
type: enhancement
versions: Python 3.6, Python 3.7, Python 3.8

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue36064>
_______________________________________


More information about the New-bugs-announce mailing list