[issue36064] docs: urllib.request.Request not accepting iterables data type

2019-02-21 Thread Lye
Lye added the comment: Hi @matrixise, Sorry that the example in that stackoverflow site is a dummy API server. I tested my code in a real API server so I can produce the error. I have re-tested my code with that dummy site and yes you won't able to get that error. To reproduce that error, y

[issue36030] add internal API function to create tuple without items array initialization

2019-02-21 Thread STINNER Victor
STINNER Victor added the comment: Please make PyTuple_FromArray private: rename to _PyTuple_FromArray. I would prefer to only add it to Include/internals/pycore_tupleobject.c. -- ___ Python tracker

[issue29757] The loop in utility `socket.create_connection()` swallows previous errors

2019-02-21 Thread STINNER Victor
STINNER Victor added the comment: > I thought that local-variables were deterministically (ref-countering) > destructed. What is happening? IT's a reference cycle. Exception => traceback => frame => exception. The 'err' variable kept the frame alive which kept the exception alive which kept

[issue36034] Suprise halt caused by -Werror=implicit-function-declaration in ./Modules/posixmodule.c

2019-02-21 Thread Michael Felt
Michael Felt added the comment: xlc has an option -qsource that creates output like this - first showing the code with macro, then showing the expansion > SOURCE SECTION < ...    16 | dev = st.st_dev;    17 | minor = minor(dev);    17 + minor = (int)(

[issue31659] ssl module should not use textwrap for wrapping PEM format.

2019-02-21 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> fixed stage: needs patch -> resolved status: open -> closed ___ Python tracker ___ ___ Py

[issue36061] zipfile does not handle arcnames with non-ascii characters on Windows

2019-02-21 Thread Inada Naoki
Change by Inada Naoki : -- resolution: -> wont fix stage: patch review -> resolved status: open -> closed ___ Python tracker ___ __

[issue36018] Add a Normal Distribution class to the statistics module

2019-02-21 Thread Raymond Hettinger
Change by Raymond Hettinger : -- keywords: +patch pull_requests: +11999 stage: -> patch review ___ Python tracker ___ ___ Python-bu

[issue12974] array module: deprecate '__int__' conversion support for array elements

2019-02-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: See more general issue36048. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue36064] docs: urllib.request.Request not accepting iterables data type

2019-02-21 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: and I get the same result with the python:3.6.7 image docker > docker run --rm -v $PWD:/src -it python:3.6.7 python /src/demo.py Traceback (most recent call last): File "/usr/local/lib/python3.6/urllib/request.py", line 1318, in do_open encode_chunked=re

[issue36064] docs: urllib.request.Request not accepting iterables data type

2019-02-21 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Hi Lye, I am not sure it's a bug because I don't have any problem with your script. Here is your script. import urllib import urllib.request my_url = "https://api.foo.com"; my_headers = { "Content-Type" : "application/x-www-form-urlencoded" } my_data = {

[issue33039] int() and math.trunc don't accept objects that only define __index__

2019-02-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Is not this a duplicate of issue20092? -- ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue36064] docs: urllib.request.Request not accepting iterables data type

2019-02-21 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Hi Lye, I didn't read your link, sorry you don't need to provide an example. We can work with this example. -- ___ Python tracker ___ __

[issue36064] docs: urllib.request.Request not accepting iterables data type

2019-02-21 Thread Stéphane Wirtel
Stéphane Wirtel added the comment: Thank you for your issue but could you provide an example file? Have a nice day. For the new contributors, this issue is marked as easy. -- keywords: +easy nosy: +matrixise ___ Python tracker

[issue36064] docs: urllib.request.Request not accepting iterables data type

2019-02-21 Thread Lye
New submission from Lye : 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

[issue36052] Assignment operator allows to assign to __debug__

2019-02-21 Thread Pablo Galindo Salgado
Change by Pablo Galindo Salgado : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue36052] Assignment operator allows to assign to __debug__

2019-02-21 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: New changeset 3ad91673057d410bf9f8c53df6bb8aa18c4b68ca by Pablo Galindo (Stéphane Wirtel) in branch 'master': bpo-36052: Raise a SyntaxError when assigning a value to __debug__ with := (GH-11958) https://github.com/python/cpython/commit/3ad91673057d410

[issue36063] replace PyTuple_SetItem() with PyTuple_SET_ITEM() in long_divmod()

2019-02-21 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue36063] replace PyTuple_SetItem() with PyTuple_SET_ITEM() in long_divmod()

2019-02-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset ea6207d593832fe50dbca39e94c138abbd5d266d by Serhiy Storchaka (Sergey Fedoseev) in branch 'master': bpo-36063: Minor performance tweak in long_divmod(). (GH-11915) https://github.com/python/cpython/commit/ea6207d593832fe50dbca39e94c138abbd5d266

[issue20177] Derby #8: Convert 28 sites to Argument Clinic across 2 files

2019-02-21 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The modern workflow requires creating a PR on GitHub. Nikolaus, do you mind to convert your patch to a PR? -- nosy: +serhiy.storchaka versions: +Python 3.8 -Python 3.5 ___ Python tracker

[issue36063] replace PyTuple_SetItem() with PyTuple_SET_ITEM() in long_divmod()

2019-02-21 Thread Sergey Fedoseev
Change by Sergey Fedoseev : -- keywords: +patch pull_requests: +11998 stage: -> patch review ___ Python tracker ___ ___ Python-bugs

[issue36063] replace PyTuple_SetItem() with PyTuple_SET_ITEM() in long_divmod()

2019-02-21 Thread Sergey Fedoseev
New submission from Sergey Fedoseev : This change produces minor speed-up: $ python-other -m perf timeit -s "divmod_ = divmod" "divmod_(1, 1)" --duplicate=1000 --compare-to=../cpython-master/venv/bin/python python: . 64.6 ns +- 4.8 ns python-other: . 59.

[issue29757] The loop in utility `socket.create_connection()` swallows previous errors

2019-02-21 Thread Kostis Anagnostopoulos
Kostis Anagnostopoulos added the comment: The problem of not fixing this (and just add a suggestion in the docs saying that the user may re-implement this method) is that frequently this call is hidden at the core of many networking libraries. So monkey-patching is needed instead, which is

[issue30782] Allow limiting the number of concurrent tasks in asyncio.as_completed

2019-02-21 Thread Andrey Paramonov
Andrey Paramonov added the comment: Might as_completed() be considered a low-level API, but as of Python 3.7 there are seemingly no ready alternatives to achieve proposed behavior. All of asyncio.gather(), asyncio.wait(), asyncio.as_completed() expect awaitables list of limited size; doing s

[issue36059] Update docs for OrderedDict to reflect that regular dicts are ordered

2019-02-21 Thread Raymond Hettinger
Raymond Hettinger added the comment: New changeset 300605990dc7441b19ab3fe7ea683094306d5ecd by Raymond Hettinger (Miss Islington (bot)) in branch '3.7': bpo-36059: Update OrderedDict() docs to reflect that regular dicts are now ordered (GH-11966) (GH-#11972) https://github.com/python/cpython

[issue36059] Update docs for OrderedDict to reflect that regular dicts are ordered

2019-02-21 Thread Raymond Hettinger
Change by Raymond Hettinger : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

[issue33989] ms.key_compare is not initialized in all paths of list_sort_impl()

2019-02-21 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue36059] Update docs for OrderedDict to reflect that regular dicts are ordered

2019-02-21 Thread miss-islington
Change by miss-islington : -- pull_requests: +11997 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://m

[issue33989] ms.key_compare is not initialized in all paths of list_sort_impl()

2019-02-21 Thread miss-islington
miss-islington added the comment: New changeset 0e73ea26a55abc0ce2ee1153e5509bcaef4736cf by Miss Islington (bot) in branch '3.7': bpo-33989: Ensure that ms.key_compare is always initialized in list_sort_impl(). (GH-8710) https://github.com/python/cpython/commit/0e73ea26a55abc0ce2ee1153e5509b

[issue36059] Update docs for OrderedDict to reflect that regular dicts are ordered

2019-02-21 Thread Raymond Hettinger
Raymond Hettinger added the comment: New changeset 49fd6dd887df6ea18dbb1a3c0f599239ccd1cb42 by Raymond Hettinger in branch 'master': bpo-36059: Update OrderedDict() docs to reflect that regular dicts are now ordered (GH-11966) https://github.com/python/cpython/commit/49fd6dd887df6ea18dbb1a3c

<    1   2