[issue31741] backports import path can not be overridden in Windows (Linux works fine)

2017-10-10 Thread Paul Moore
Paul Moore added the comment: The "backports" module you refer to as being in site-packages is not shipped with the standard library, it's a 3rd party addon that presumably you installed yourself. You'll need to let us know what you did to install it. You say you

[issue31735] Documentation incorrectly states how descriptors are invoked

2017-10-10 Thread Henk-Jaap Wagenaar
Henk-Jaap Wagenaar added the comment: I do think though that "If d defines the method __get__(), then d.__get__(obj) is invoked according to the precedence rules listed below." seems to contain a mistake in that it should have d.__get__(obj, type(obj)) instead of

[issue31415] Add -X option to show import time

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: New changeset a997c7b434631f51e00191acea2ba6097691e859 by Victor Stinner in branch 'master': bpo-31415: Add _PyTime_GetPerfCounter() and use it for -X importtime (#3936)

[issue31735] Documentation incorrectly states how descriptors are invoked

2017-10-10 Thread Henk-Jaap Wagenaar
Henk-Jaap Wagenaar added the comment: "We know this doesn't happen because nothing is printed to stdout." Try running Obj().d, you will get output. Obj.d does not work because it is on a *class*, and so it runs, per the docs: 'Obj.__dict__['d'].__get__(None, Obj)'

[issue31743] Proportional Width Font on Generated Python Docs PDFs

2017-10-10 Thread Ante Perić
New submission from Ante Perić : Fonts in the generated documentation PDFs, for all Python versions, are proportional width in code blocks, unlike in HTML version, where they are fixed-width. Example https://docs.python.org/2.7/archives/python-2.7.14-docs-pdf-a4.zip

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I don't think that a special way for silencing FutureWarning is needed. You can use an existing mechanism. import warnings warnings.filterwarnings('ignore', '', FutureWarning, 'typing') -- nosy:

[issue31705] test_sha256 from test_socket fails on ppc64le arch

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: > strace is maybe outdated and fails to display the full bind() address, I vote for this option since I see addrlen=88 in both examples. -- ___ Python tracker

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Nick Coghlan
Nick Coghlan added the comment: The deprecation warnings weren't turned off due to Python developers running things in virtual environments - they were turned off due to Linux distros upgrading their system Python runtimes, and Linux ISVs getting an influx of new bug

[issue31705] test_sha256 from test_socket fails on ppc64le arch

2017-10-10 Thread Charalampos Stratakis
Charalampos Stratakis added the comment: Indeed the version of strace is 'strace-4.12-4.el7'. I will try to provide output from the latest one. -- ___ Python tracker

[issue31745] Overloading "Py_GetPath" does not work

2017-10-10 Thread Kay Hayen
New submission from Kay Hayen : Hello, for my Python compiler Nuitka, I want to make sure that compiled binaries in standalone mode do not access the original installation, but solely the distribution folder created. I am using the new API Py_SetPath on Python3 and it

[issue31746] crashes in sqlite3.Connection in case it is uninitialized or partially initialized

2017-10-10 Thread Oren Milman
New submission from Oren Milman : The following code causes a crash: import sqlite3 connection = sqlite3.Connection.__new__(sqlite3.Connection) connection.isolation_level This is because pysqlite_connection_get_isolation_level() doesn't check whether the Connection object is

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread R. David Murray
R. David Murray added the comment: I think there needs to be an easy way to turn off the warnings while running tests, as well. I don't want to be bothered by those messages when testing parts of my package that are consciously using the provisional features. But

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Amber Brown
Amber Brown added the comment: So you're proposing a coordinated effort across the half dozen, possibly more, test runners to enable some flags, so CPython doesn't log a single message, possibly two, that you're using unsupported experimental software with no

[issue31719] [2.7] test_regrtest.test_crashed() fails on s390x

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: > Why not use just abort() or Py_FatalError()? I try to test how a real program crash, like a real invalid memory read. Maybe it doesn't matter much here. -- ___ Python tracker

[issue31744] Python 2.7.14 Fails to compile on CentOS/RHEL7

2017-10-10 Thread Brian Sidebotham
New submission from Brian Sidebotham : I am getting the following error when trying to compile Python 2.7.14 (and previous 2.7 versions) on CentOS and RHEL7. The main problem is that CONFIG_ARGS does not exist. I've included the build. This RPATH is correct - it has

Re: [issue31744] Python 2.7.14 Fails to compile on CentOS/RHEL7

2017-10-10 Thread M.-A. Lemburg
I'm not sure whether this is related, but your quoting for --rpath doesn't appear to work: On 10.10.2017 14:17, Brian Sidebotham wrote: > LDFLAGS='-Wl,-rpath=$\\$$ORIGIN/../lib' \ > ... > gcc -pthread -Wl,-rpath=RIGIN/../lib -fprofile-generate -Xlinker > -export-dynamic -o python \ >

[issue30008] OpenSSL 1.1.0 deprecated functions

2017-10-10 Thread Mark Wright
Change by Mark Wright : -- pull_requests: +3915 ___ Python tracker ___ ___

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Nick Coghlan
Nick Coghlan added the comment: A note regarding *only* using the warnings module to turn things off: The problem I have with that is that the UX is relatively clumsy, and hence runs into the concern Guido mentions above: "having this warning pop up every time you import

[issue31744] Python 2.7.14 Fails to compile on CentOS/RHEL7

2017-10-10 Thread Charalampos Stratakis
Charalampos Stratakis added the comment: Which CentOS/RHEL version do you have? Could you provide the output of 'cat /etc/redhat-release' ? -- nosy: +cstratak ___ Python tracker

[issue31740] refleaks when calling sqlite3.Connection.__init__() more than once

2017-10-10 Thread Oren Milman
Change by Oren Milman : -- keywords: +patch pull_requests: +3917 stage: -> patch review ___ Python tracker ___

[issue30008] OpenSSL 1.1.0 deprecated functions

2017-10-10 Thread Mark Wright
Mark Wright added the comment: Thanks, I opened https://github.com/python/cpython/pull/3943 for the rest of the changes (on top of your changes in https://github.com/python/cpython/pull/3934) to allow it to compile with OpenSSL 1.1.0f compiled with disable-deprecated.

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Amber Brown
Amber Brown added the comment: What is the point of an opt-in warning, when the entire point of the proposed warning is letting people know that they may be using something they are not fully educated or informed about the ramifications of using? If you know to

[issue31705] test_sha256 from test_socket fails on ppc64le arch

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: Charalampos Stratakis: "Attaching the strace output." Oh thanks! I guess tha the interesting syscalls are: socket(AF_ALG, SOCK_SEQPACKET|SOCK_CLOEXEC, 0) = 3 bind(3, {sa_family=AF_ALG, sa_data="hash\0\0\0\0\0\0\0\0\0\0"}, 88) = 0

[issue31744] Python 2.7.14 Fails to compile on CentOS/RHEL7

2017-10-10 Thread Iryna Shcherbina
Change by Iryna Shcherbina : -- nosy: +ishcherb ___ Python tracker ___ ___

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread R. David Murray
R. David Murray added the comment: I imagine we could make it controlled by the same setting that controls deprecation warnings, with some way to differentiate them if you really need to. I forget exactly how that warning control works, so maybe that would be awkward,

[issue31744] Python 2.7.14 Fails to compile on CentOS/RHEL7

2017-10-10 Thread Ned Deily
Ned Deily added the comment: Do you already have an existing version of Python 2.7 installed at the prefix location /opt/ws1? Because you are attempting to build with --enable-shared, the build may be picking up the already installed shared library. Try building without

[issue31740] refleaks when calling sqlite3.Connection.__init__() more than once

2017-10-10 Thread Oren Milman
Oren Milman added the comment: (opened bpo-31746 for the crashes i mentioned) -- ___ Python tracker ___

[issue31415] Add -X option to show import time

2017-10-10 Thread STINNER Victor
Change by STINNER Victor : -- pull_requests: +3914 ___ Python tracker ___ ___

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread R. David Murray
R. David Murray added the comment: That's why I said set on by default by the test harnesses. The opt in would be done by the standard testing tools, not directly by the programmer. That's how deprecation warnings work now. --

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Nick Coghlan
Nick Coghlan added the comment: Deprecation warnings were different: we turned those off by default because currently working applications could start emitting console warnings simply because an end user ran them on a newer version of Python. With future warnings, we're

[issue26546] Provide translated french translation on docs.python.org

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: Since you closed the issue, Julien, I changed the status of the PEP 545 to Final: https://github.com/python/peps/commit/14092e51dea5c5c6391458da4a2ad92adad227b9 -- ___ Python tracker

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread R. David Murray
R. David Murray added the comment: Nick says: "Neither of those situations can be encountered simply by running an existing *application* on a newer version of Python". I fail to see the operational difference between running an application on a newer version of

[issue31744] Python 2.7.14 Fails to compile on CentOS/RHEL7

2017-10-10 Thread Ned Deily
Change by Ned Deily : -- nosy: +ishcherb ___ Python tracker ___ ___ Python-bugs-list

[issue6135] subprocess seems to use local encoding and give no choice

2017-10-10 Thread Andrew Clegg
Andrew Clegg added the comment: The commit for this bug (720f0cf580e2) introduces encoding and errors arguments but doesn't actually document what the values of these should be. In the case of the encoding it could be reasonably guessed, but the only way to

[issue31749] Request: Human readable byte amounts in the standard library

2017-10-10 Thread Michael DePalatis
Michael DePalatis added the comment: This would be a useful feature, but I don't think it quite fits in the math package. It might make more sense to use this with string formatting, for example: {:h}.format(filesize) where I use h as the format specifier since it

[issue31747] fatal error LNK1120 in PCbuild\python3dll.vcxproj

2017-10-10 Thread Denis Osipov
Denis Osipov added the comment: Oops... I've tried to rebuild, it didn't help. But after deleting folder cpython\PCbuild\amd64 everything works well again. Sorry for false alarm. -- resolution: -> works for me stage: -> resolved status: open -> closed

[issue6135] subprocess seems to use local encoding and give no choice

2017-10-10 Thread Steve Dower
Steve Dower added the comment: > The commit for this bug (720f0cf580e2) introduces encoding and errors > arguments but doesn't actually document what the values of these should be Do you mean it doesn't document that they take the normal encoding/errors arguments that

[issue31749] Request: Human readable byte amounts in the standard library

2017-10-10 Thread Rich
New submission from Rich : This problem is an _extremely_ common one, a problem that almost any Python project of a reasonable size will encounter. Given a number of bytes, say 123901842, format this as '123.9MB'. The reason I strongly think that this should be

[issue31750] expose PyCell_Type in types module

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: According to discussions in the issues referred by you, this omission is intentional. Do you have any new arguments for adding the cell type in the types module? -- nosy: +serhiy.storchaka versions: +Python 3.7 -Python

[issue13601] sys.stderr should be line-buffered when stderr is not a TTY

2017-10-10 Thread Torsten Landschoff
Torsten Landschoff added the comment: > Looking at > http://pubs.opengroup.org/onlinepubs/9699919799/functions/stdin.html (which > also covers stdout and stderr), it specifically says about stderr: "When > opened, the standard error stream is not fully buffered;". I

[issue31750] expose PyCell_Type in types module

2017-10-10 Thread Devin Bayer
Devin Bayer added the comment: I have just reread those discussions and I don't see any reasoning behind omitting the cell type. It is barely mentioned. Basically, I need this type and it isn't exposed anywhere. I don't care where it is, but the only way to get it right now

[issue31748] Modules/posixmodule.c: skip compiling jka4NaPmmQ37 and posix_fildes_fd

2017-10-10 Thread Дилян Палаузов
New submission from Дилян Палаузов : These are needed only sometimes. diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c --- a/Modules/posixmodule.c +++ b/Modules/posixmodule.c @@ -1466,6 +1466,7 @@ path_error2(path_t *path, path_t *path2) /* POSIX generic

[issue31750] expose PyCell_Type in types module

2017-10-10 Thread Devin Bayer
New submission from Devin Bayer : The type of PyCell_Type is not available in the types module or anywhere else. Since this type is exposed to users it seems like it's a rather odd omission. Related issues: - https://bugs.python.org/issue2408 - https://bugs.python.org/issue1605

[issue31738] Lib/site.py: method `abs_paths` is not documented

2017-10-10 Thread Liel Fridman
Liel Fridman added the comment: No, I've just tried to find something to work on as a first contribution. -- ___ Python tracker ___

[issue31751] Support for C++ 11 and/or C++ 14 in python.org installer

2017-10-10 Thread steven Michalske
New submission from steven Michalske : We are using some compiled cython modules with c++ 11 features. This prohibits us from instructing users to install python from the python.org download. Please consider using clang with support for C++ 11 and higher. This would move

[issue31705] test_sha256 from test_socket fails on ppc64le arch

2017-10-10 Thread Charalampos Stratakis
Charalampos Stratakis added the comment: Attaching the output of: strace -s 128 -e trace=%network -o trace ./python3 -m test -v test_socket -m test_sha256 using the latest version of strace (4.19). -- Added file: https://bugs.python.org/file47204/trace2

[issue31672] string.Template should use re.ASCII flag

2017-10-10 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: With some comments to clarify of course. -- ___ Python tracker ___

[issue31672] string.Template should use re.ASCII flag

2017-10-10 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: On Oct 6, 2017, at 15:04, Serhiy Storchaka wrote: > Serhiy Storchaka added the comment: > > Another solution (works in 3.6 too): set idpattern to > r'(?-i:[_a-zA-Z][_a-zA-Z0-9]*)'. > >

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Guido van Rossum
Guido van Rossum added the comment: I have no bandwidth for this discussion, but so far I am not convinced. What happened to "consenting adults"? > [...] the entire point of the proposed warning letting people know that they > may be using something they are not fully

[issue14369] make __closure__ writable

2017-10-10 Thread Devin Bayer
Devin Bayer added the comment: Any updates on this? I'm trying to implement hot module reloading using code from IPython, which tries to modify __closure__ in place. It fails silently and doesn't work, but indeed would be nice to have. --

[issue31733] [2.7] Add PYTHONSHOWREFCOUNT environment variable to Python 2.7

2017-10-10 Thread Charalampos Stratakis
Change by Charalampos Stratakis : -- nosy: +cstratak ___ Python tracker ___ ___

[issue31747] fatal error LNK1120 in PCbuild\python3dll.vcxproj

2017-10-10 Thread Denis Osipov
New submission from Denis Osipov : Since today (2017-10-10) I have compile error on Windows 10: $ PCbuild/build.bat -e -d -p x64 Using py -3.6 (found with py.exe) Fetching external libraries... bzip2-1.0.6 already exists, skipping. sqlite-3.14.2.0 already exists, skipping.

[issue14369] make __closure__ writable

2017-10-10 Thread Devin Bayer
Change by Devin Bayer : -- nosy: +akvadrako ___ Python tracker ___ ___ Python-bugs-list

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Donald Stufft
Donald Stufft added the comment: > What happened to "consenting adults"? Making sure they're actually consenting when getting into something that might potentially bite them in the ass seems like a sane and thoughtful thing to do to me. --

[issue1927] Change input() to always prompt to stderr

2017-10-10 Thread Carvell Scott
Change by Carvell Scott : -- nosy: +Carvell Scott ___ Python tracker ___ ___

[issue31314] email throws exception with oversized header input

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: PR 3938 fixes this issue, but I'm wondering why self._split() returns an empty list only for long header names. -- nosy: +serhiy.storchaka ___ Python tracker

[issue31722] _io.IncrementalNewlineDecoder doesn't inherit codecs.IncrementalDecoder

2017-10-10 Thread Oren Milman
Change by Oren Milman : -- keywords: +patch pull_requests: +3918 stage: -> patch review ___ Python tracker ___

[issue31750] expose PyCell_Type in types module

2017-10-10 Thread Devin Bayer
Devin Bayer added the comment: Well that's true enough. My main argument is consistency. Cells and code objects together make up closures, so to manipulate closures you need both. Right now I am using a ctypes hack to modify the cells/closures, for what I consider a

[issue31748] Modules/posixmodule.c: skip compiling jka4NaPmmQ37 and posix_fildes_fd

2017-10-10 Thread Дилян Палаузов
Дилян Палаузов added the comment: Having 'CFLAGS="-pipe -Werror -Wall -Wextra -O3 -fno-fat-lto-objects -flto" CXXFLAGS="-pipe -Wall -Wextra -O3 -fno-fat-lto-objects -flto" LDFLAGS="-Wl,-O1,-s -flto=12" ' in config.site and running "./configure" with gcc8 prints:

[issue31728] crashes in _elementtree due to unsafe decrefs of Element.text and Element.tail

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 39ecb9c71b6e55d8a61a710d0144231bd88f9ada by Serhiy Storchaka (Oren Milman) in branch 'master': bpo-31728: Prevent crashes in _elementtree due to unsafe cleanup of Element.text and Element.tail (#3924)

[issue31722] _io.IncrementalNewlineDecoder doesn't inherit codecs.IncrementalDecoder

2017-10-10 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: -3918 ___ Python tracker ___

[issue31740] refleaks when calling sqlite3.Connection.__init__() more than once

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: New changeset 93c5a5df8ea118f6e4a153a7c8cccd65a5ff8bff by Victor Stinner (Oren Milman) in branch 'master': bpo-31740: Prevent refleaks when sqlite3.Connection.__init__() is called more than once (GH-3944)

[issue31740] refleaks when calling sqlite3.Connection.__init__() more than once

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: Oren Milman: thanks for your contribution! I merged your PR. I don't consider that such corner case requires to backport the change to Python 2.7 and 3.6. -- resolution: -> fixed stage: patch review -> resolved status: open

[issue31748] Modules/posixmodule.c: skip compiling jka4NaPmmQ37 and posix_fildes_fd

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: Hi Дилян Палаузов, > These are needed only sometimes. Would you mind to elaborate, please? Which platform doesn't have os.fchdir(), os.fsync() nor os.fdatasync()? -- nosy: +haypo ___

[issue31750] expose PyCell_Type in types module

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: The reason is that nobody provided good enough arguments for exposing a cell type in the types module. The initial argument "types should expose all types used by the interpreter" was found to be bad. There are a lot of types

[issue31749] Request: Human readable byte amounts in the standard library

2017-10-10 Thread Timothy Allen
Timothy Allen added the comment: This would be a benefit to my team, for sure. I can't even tell you how many different solutions we currently use to make file sizes human readable - at least three. -- nosy: +FlipperPA ___

[issue31748] Modules/posixmodule.c: skip compiling jka4NaPmmQ37 and posix_fildes_fd

2017-10-10 Thread Дилян Палаузов
Дилян Палаузов added the comment: If I remove -Werror from CFLAGS ./configure prints: checking for fchdir... yes checking for fsync... yes checking for fdatasync... yes so it is irrelevant what the OS is. -- ___

[issue31749] Request: Human readable byte amounts in the standard library

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do you mean decimal or binary prefixes? 123901842 bytes can be formatted as "118.2 MiB". In different areas decimal and binary prefixes can be more common. For example the volume of hard disks usually is specified with decimal

[issue31748] Modules/posixmodule.c: skip compiling jka4NaPmmQ37 and posix_fildes_fd

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: Ok. My next question is: what is your operating system? What is your operating system version? -- ___ Python tracker

[issue31750] expose PyCell_Type in types module

2017-10-10 Thread Guido van Rossum
Guido van Rossum added the comment: I think the cell type is pretty fundamental to Python's semantic model. IIRC there once was a time when cells were entirely hidden from the user, but that's no longer true. Third-party code that uses them might want to have type

[issue31728] crashes in _elementtree due to unsafe decrefs of Element.text and Element.tail

2017-10-10 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +3919 ___ Python tracker ___

[issue31751] Support for C++ 11 and/or C++ 14 in python.org installer

2017-10-10 Thread Ned Deily
Ned Deily added the comment: Can you give a test case demonstrating what is not working? The Python interpreters installed with python.org 10.6+ installers are built to work with all versions of macOS from 10.6 on and should be able to build extension modules with either

[issue31728] crashes in _elementtree due to unsafe decrefs of Element.text and Element.tail

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset a8ac71d15f2a4aef83a8954a678cc12545ce517c by Serhiy Storchaka (Miss Islington (bot)) in branch '3.6': [3.6] bpo-31728: Prevent crashes in _elementtree due to unsafe cleanup of Element.text and Element.tail

[issue31748] configure fails to detect fchdir() using CFLAGS="-Werror -Wall"

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: I can reproduce the issue on Fedora 26: haypo@selma$ ./configure CFLAGS="-Werror -Wall" 2>&1|tee log haypo@selma$ grep fchdir log checking for fchdir... no The problem is not posixmodule.c. The problem is configure which emits a

[issue31749] Request: Human readable byte amounts in the standard library

2017-10-10 Thread Rich
Rich added the comment: Yep, as I mentioned, it should be configurable to use either format. Localization is an excellent point as well, so, all in all, the optional arguments to the function are format, significant digits, and delimiter. That's not an

[issue31746] crashes in sqlite3.Connection in case it is uninitialized or partially initialized

2017-10-10 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch pull_requests: +3920 stage: -> patch review ___ Python tracker ___

[issue31752] Assertion failure in timedelta() in case of bad __divmod__

2017-10-10 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- keywords: +patch pull_requests: +3922 ___ Python tracker ___

[issue31537] Bug in readline module documentation example

2017-10-10 Thread Roundup Robot
Change by Roundup Robot : -- pull_requests: +3923 ___ Python tracker ___

[issue31748] configure fails to detect fchdir() using CFLAGS="-Werror -Wall"

2017-10-10 Thread STINNER Victor
STINNER Victor added the comment: Python 2.7 is also affected by the issue. -- versions: +Python 2.7, Python 3.6, Python 3.7 -Python 3.8 ___ Python tracker

[issue31752] Assertion failure in timedelta() in case of bad __divmod__

2017-10-10 Thread Serhiy Storchaka
New submission from Serhiy Storchaka : The following code causes an assertion error in timedelta constructor. from datetime import timedelta class BadInt(int): def __mul__(self, other): return Prod() class Prod: def __radd__(self, other):

[issue31537] Bug in readline module documentation example

2017-10-10 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset eeb5ffd54e56dd89a99c74eb512c36d62649cfec by Mariatta (Brad Smith) in branch 'master': bpo-31537: Update readline documentation example. (GH-3925)

[issue31753] Unnecessary closure in ast.literal_eval

2017-10-10 Thread Aaron Hall
New submission from Aaron Hall : Removing the closure seems to make the function about 10% faster. Original source code at: https://github.com/python/cpython/blob/3.6/Lib/ast.py#L40 Empirical evidence: astle.py import timeit from ast import literal_eval as

[issue31537] Bug in readline module documentation example

2017-10-10 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: Fixed. Thanks! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: -Python 3.5 ___ Python tracker

[issue31537] Bug in readline module documentation example

2017-10-10 Thread Mariatta Wijaya
Mariatta Wijaya added the comment: New changeset 10eb14e2c5fe08c4193668530eaef156e07c3674 by Mariatta (Miss Islington (bot)) in branch '3.6': bpo-31537: Update readline documentation example. (GH-3925) (GH-3948)

[issue31753] Unnecessary closure in ast.literal_eval

2017-10-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Test more complex examples including list and dict displays, binary operators. -- nosy: +serhiy.storchaka ___ Python tracker

[issue31589] Links for French documentation PDF is broken: LaTeX issue with non-ASCII characters?

2017-10-10 Thread Julien Palard
Julien Palard added the comment: Today I tried without utf8x and an up-to-date version of texlive, errors looked less mystical, so I was able to open a readable / easy to reproduce issue: https://github.com/sphinx-doc/sphinx/issues/4136 I then followed the idea of

[issue31589] Links for French documentation PDF is broken: LaTeX issue with non-ASCII characters?

2017-10-10 Thread Roundup Robot
Change by Roundup Robot : -- keywords: +patch pull_requests: +3913 stage: -> patch review ___ Python tracker ___

[issue27172] Undeprecate inspect.getfullargspec()

2017-10-10 Thread Nick Coghlan
Nick Coghlan added the comment: Larry, your personal insult is entirely unwelcome, unnecessary, and unappreciated, especially as it's wrong regarding the Python 2/3 compatibility concerns. While getfullargspec() is indeed new in Python 3.x, it's also deliberately

[issue27172] Undeprecate inspect.getfullargspec()

2017-10-10 Thread Nick Coghlan
Nick Coghlan added the comment: Note: the minor incompatibility that required getfullargspec() to be a separate API in the first place is the fact that it returns a 7 element named tuple instead of a 4 element one. This means that hybrid 2/3 code needs to consistently use

[issue31584] Documentation Language mixed up

2017-10-10 Thread INADA Naoki
INADA Naoki added the comment: https://twitter.com/miyagawa/status/917629042278359040 Miyagawa-san, the member of Fastly told me they doesn't use HTML content for cache key, unless we customize VCL. But I can't find VCL for docs.python.org in github.com/python.

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Nick Coghlan
Nick Coghlan added the comment: I think if someone is going to be put off by a FutureWarning, then that indicates they're not yet familiar with just what the provisional API status means, and those are exactly the folks we *want* to scare away from provisional APIs (or

[issue30457] Allow retrieve the number of waiters pending for most of the asyncio lock primitives

2017-10-10 Thread Yury Selivanov
Yury Selivanov added the comment: Isn't this code equivalent to yours: async def get(process, key): try: return cache[key] except KeyError: if key in events: await events[key].wait() else: events[key] =

[issue31749] Request: Human readable byte amounts in the standard library

2017-10-10 Thread Eric V. Smith
Eric V. Smith added the comment: A library implementing this should definitely go on PyPI first to shake out design issues. Then we'd need a PEP. As someone who has a simplistic version of this code around, and who's done a bit of string formatting, I can assure you that

[issue31741] backports import path can not be overridden in Windows (Linux works fine)

2017-10-10 Thread Chris Caron
Chris Caron added the comment: I'm not doing anything unusual. Just to recap, I installed Python27 (in Windows 7 in my case- but this problem happens in Windows 10 too). I did use `pip` to install packages as you'll see in the screenshot. But even if i rename the

[issue31741] backports import path can not be overridden in Windows (Linux works fine)

2017-10-10 Thread Chris Caron
Change by Chris Caron : Added file: https://bugs.python.org/file47206/site-packages-Directory.png ___ Python tracker ___

[issue31456] SimpleCookie fails to parse any cookie if an entry has whitespace in the name

2017-10-10 Thread Adam Davis
Adam Davis added the comment: Quietly throw out the one bad value, sure. You lose all cookies in your cookie string in this scenario. I'd expect "ASDF=stuff; ASDF space=more stuff" to at least kick out the values that are legal. --

[issue31456] SimpleCookie fails to parse any cookie if an entry has whitespace in the name

2017-10-10 Thread Brad Smith
Brad Smith added the comment: According to RFC-6265 (which also references RFC-2616 to define "tokens"), the space character (and whitespace in general) is not valid in cookie-names or cookie-values. RFC-6265: https://tools.ietf.org/html/rfc6265#section-4.1.1 RFC-2616:

[issue31314] email throws exception with oversized header input

2017-10-10 Thread Dong-hee Na
Dong-hee Na added the comment: And my patch was wrong, I will re-upload it soon. 2017-10-11 13:51 GMT+09:00 Dong-hee Na : > > Dong-hee Na added the comment: > > I found that when email header's self._firstlinelen value is

[issue31754] Documented type of parameter 'itemsize' to PyBuffer_FillContiguousStrides is incorrect.

2017-10-10 Thread Robert Snoeberger
New submission from Robert Snoeberger : The signature for PyBuffer_FillContiguousStrides in the documentation shows that the type of parameter 'itemsize' is Py_ssize_t [1]. This is different from the signature in Include/abstract.h which shows that the type as int

[issue31742] Default to emitting FutureWarning for provisional APIs

2017-10-10 Thread Amber Brown
Amber Brown added the comment: > What happened to "consenting adults"? Consent does not mean that by using Python, users fully consent to using modules that they may not be aware will, to paraphrase Donald, come back to bite them in the ass. Consent requires

  1   2   >