[issue29571] test_re is failing when local is set for `en_IN`

2017-03-07 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- pull_requests: +456 ___ Python tracker <http://bugs.python.org/issue29571> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue20087] Mismatch between glibc and X11 locale.alias

2017-03-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: Why is the X11 locale alias map used at all? It seems like it can only create confusion with libc. -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue20

[issue29571] test_re is failing when local is set for `en_IN`

2017-03-07 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- pull_requests: +455 ___ Python tracker <http://bugs.python.org/issue29571> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue29571] test_re is failing when local is set for `en_IN`

2017-03-06 Thread Benjamin Peterson
Benjamin Peterson added the comment: I don't see what's odd about it. re.LOCALE uses the C locale, which one obtains from locale.getlocale(). getpreferredencoding() is not documented to have anything to do with the C locale, and indeed on Windows it may be completely

[issue29571] test_re is failing when local is set for `en_IN`

2017-03-05 Thread Benjamin Peterson
Benjamin Peterson added the comment: getpreferredencoding() takes a completely different path on windows (returns a codepage) and isn't related to the C locale. -- ___ Python tracker <http://bugs.python.org/is

[issue29571] test_re is failing when local is set for `en_IN`

2017-03-05 Thread Benjamin Peterson
Benjamin Peterson added the comment: But the test was never broken on windows. On Sun, Mar 5, 2017, at 23:54, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > I'm not sure this will help on Windows. > > -- > > ___

[issue29571] test_re is failing when local is set for `en_IN`

2017-03-05 Thread Benjamin Peterson
Benjamin Peterson added the comment: Yep, I think we should merge https://github.com/python/cpython/pull/422 and revert ncoghlan's change. -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/is

[issue29571] test_re is failing when local is set for `en_IN`

2017-03-02 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- pull_requests: +352 ___ Python tracker <http://bugs.python.org/issue29571> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue20087] Mismatch between glibc and X11 locale.alias

2017-03-02 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- pull_requests: +351 ___ Python tracker <http://bugs.python.org/issue20087> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue10513] sqlite3.InterfaceError after commit

2017-01-11 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: fixed -> status: closed -> open ___ Python tracker <http://bugs.python.org/issue10513> ___ ___ Python-bugs-

[issue29215] pyport.h uses non C90-style comment

2017-01-09 Thread Benjamin Peterson
Benjamin Peterson added the comment: C99 is required to build or include Python headers since 3.6. PEP 7 could be clearer. The bullet about C99 is meant to override for 3.6 other directives such as the comment prohibition. -- resolution: -> not a bug status: open ->

[issue29145] failing overflow checks in replace_*

2017-01-03 Thread Benjamin Peterson
Benjamin Peterson added the comment: Does that mean it no longer respects -fwrapv? -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue29

[issue29136] Add OP_NO_TLSv1_3

2017-01-02 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think that's fine for 2.7. On Mon, Jan 2, 2017, at 13:07, Christian Heimes wrote: > > New submission from Christian Heimes: > > OpenSSL 1.1.1 is going to provide TLS 1.3. The preferred protocols > PROTOCOL_TLS (old

[issue29094] Regression in zipfile writing in 2.7.13

2017-01-01 Thread Benjamin Peterson
Benjamin Peterson added the comment: Is there a reason to ever not use relative offsets? It seems that's strictly more general the absolute. -- ___ Python tracker <http://bugs.python.org/is

[issue29101] Nested lambdas in setattr() lose context in Python 2.7

2016-12-28 Thread Benjamin Peterson
Benjamin Peterson added the comment: https://docs.python.org/2/faq/programming.html#why-do-lambdas-defined-in-a-loop-with-different-values-all-return-the-same-result -- nosy: +benjamin.peterson resolution: -> not a bug status: open ->

[issue29091] Python 3.5+ socket.socketpair fallback incorrectly implemented

2016-12-28 Thread Benjamin Peterson
Benjamin Peterson added the comment: Are you using that implementation on Python 2? Python 3's socket.listen has one optional backlog argument. -- nosy: +benjamin.peterson resolution: -> not a bug status: open -> closed ___ Python tra

[issue29094] Regression in zipfile writing in 2.7.13

2016-12-28 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- assignee: -> serhiy.storchaka nosy: +serhiy.storchaka ___ Python tracker <http://bugs.python.org/issue29094> ___ ___ Python-

[issue29057] Compiler failure on Mac OS X - sys/random.h

2016-12-27 Thread Benjamin Peterson
Benjamin Peterson added the comment: Right, my question is why does configure define HAVE_SYS_RANDOM_H if including sys/random.h causes an error? -- ___ Python tracker <http://bugs.python.org/issue29

[issue29057] Compiler failure on Mac OS X - sys/random.h

2016-12-23 Thread Benjamin Peterson
Benjamin Peterson added the comment: So, if sys/random.h can't be included without error why does the configure check for it work? -- ___ Python tracker <http://bugs.python.org/is

[issue5322] Python 2.6 object.__new__ argument calling autodetection faulty

2016-12-14 Thread Benjamin Peterson
Benjamin Peterson added the comment: BTW, at least for #25731, I think the right approach in the MI case is to synthesize a __new__ on the subclass that calls the solid base __new__. -- ___ Python tracker <http://bugs.python.org/issue5

[issue28898] Can't compile gdb with Python 3.6

2016-12-08 Thread Benjamin Peterson
Benjamin Peterson added the comment: Why do you think this change caused that breakage? That bot looks like it's been broken for days. This change should have no behavior change whatsoever for Python itself. -- ___ Python tracker

[issue28898] Can't compile gdb with Python 3.6

2016-12-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think we should take this for 3.6. -- assignee: -> ned.deily nosy: +ned.deily priority: normal -> release blocker ___ Python tracker <http://bugs.python.org/i

[issue28862] test_import.py leaks on 2.7

2016-12-03 Thread Benjamin Peterson
New submission from Benjamin Peterson: It looks like the test if not the fix for #15578 reveals a reference leak somewhere in the import system: $ ./python Lib/test/regrtest.py -R :: test_import [1/1] test_import beginning 9 repetitions 123456789 . test_import leaked [1, 1, 1, 1

[issue28855] Compiler warnings in _PyObject_CallArg1()

2016-12-01 Thread Benjamin Peterson
Benjamin Peterson added the comment: I also think forcing callers to cast is fine. Most of our APIs require PyObject *. -- ___ Python tracker <http://bugs.python.org/issue28

[issue28855] Compiler warnings in _PyObject_CallArg1()

2016-12-01 Thread Benjamin Peterson
Benjamin Peterson added the comment: (Sorry, I noticed and landed a fix before completely reading the issue.) -- ___ Python tracker <http://bugs.python.org/issue28

[issue28855] Compiler warnings in _PyObject_CallArg1()

2016-12-01 Thread Benjamin Peterson
Benjamin Peterson added the comment: It doesn't seem like the question is whether to use inline functions but whether to force all callers to cast. Your original code would work if you added all the casts in your static_inline.patch

[issue27647] Update Windows build to Tcl/Tk 8.6.6

2016-11-30 Thread Benjamin Peterson
Benjamin Peterson added the comment: I don't mind if it gets updated. On Wed, Nov 30, 2016, at 00:01, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > Why not? 8.5.15 is 3 years old. There were 4 bugfix

[issue27647] Update Windows build to Tcl/Tk 8.6.6

2016-11-29 Thread Benjamin Peterson
Benjamin Peterson added the comment: Doesn't seem terribly urgent, so maybe not 2.7.13. -- ___ Python tracker <http://bugs.python.org/issue27647> ___ ___

[issue28825] socket.SO_KEEPALIVE does not work on FreeBSD

2016-11-28 Thread Benjamin Peterson
Benjamin Peterson added the comment: Python just passes socket options to the operating system, so whatever behavior you're seeing is likely part of the OS. -- nosy: +benjamin.peterson resolution: -> not a bug status: open -> closed ___

[issue28288] Expose environment variable for Py_Py3kWarningFlag

2016-11-25 Thread Benjamin Peterson
Benjamin Peterson added the comment: Yes, I suppose this falls under the general exemption in 2.x for -3 warning changes. On Fri, Nov 25, 2016, at 09:13, Berker Peksag wrote: > > Berker Peksag added the comment: > > Roy's patch looks good to me in general. Benjamin, as the RM

[issue28555] provid also sha-1 and sha-256 also on download links

2016-11-08 Thread Benjamin Peterson
Benjamin Peterson added the comment: If python.org can be MITMed, it doesn't matter how secure the hash is. On Tue, Nov 8, 2016, at 11:17, Big Stone wrote: > > Big Stone added the comment: > > I fear GPG is not easy stuff for Windows users. > > I fear a bunch of peo

[issue28555] provid also sha-1 and sha-256 also on download links

2016-11-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: md5 is provided to verify the integrity of the download only. Use the GPG signatures to verify authenticity if the fact that all the downloads are served over HTTPS is insufficient. -- nosy: +benjamin.peterson resolution: -> wont fix status: o

[issue28092] Build failure for 3.6 on Centos 5.11

2016-10-20 Thread Benjamin Peterson
Benjamin Peterson added the comment: I changed the dtrace stubs to static inline. Probably should reopen an investigation for 3.7. I would like to have exportable inlines. -- resolution: -> fixed status: open -> closed ___ Python tracker

[issue28092] Build failure for 3.6 on Centos 5.11

2016-10-14 Thread Benjamin Peterson
Benjamin Peterson added the comment: Any different results with CFLAGS="-fno-gnu89-inline"? -- ___ Python tracker <http://bugs.python.org/issue28092> ___ ___

[issue28345] 8/3 is calculated incorrectly

2016-10-02 Thread Benjamin Peterson
Benjamin Peterson added the comment: Please see https://docs.python.org/3/tutorial/floatingpoint.html Python 3.5.2 (default, Sep 10 2016, 08:21:44) [GCC 5.4.0 20160609] on linux Type "help", "copyright", "credits" or "license" for more information. >

[issue28316] descriptor and repr get into conflict

2016-09-29 Thread Benjamin Peterson
Benjamin Peterson added the comment: This is no different than this simpler case: class A: def __init__(self, name): print("init {!r}".format(self)) self.name = name def __repr__(self): return "I am {}".format(self.name) The instance of A doe

[issue28284] Memory corruption due to size expansion (overflow) in _json.encode_basestring_ascii on 32 bit Python 2.7.12

2016-09-26 Thread Benjamin Peterson
New submission from Benjamin Peterson: Guido Vranken reports: This results in a segmentation fault on 32 bit: python -c "import _json; print _json.encode_basestring_ascii(unicode(chr(0x22)) * 0x2AAB)" This is a tentative patch: diff --git a/Modules/_json.c b/Modules/_js

[issue27482] heap-buffer-overflow on address 0x6250000078ff

2016-09-19 Thread Benjamin Peterson
Benjamin Peterson added the comment: ASan is quiet on the POC now. -- resolution: -> fixed status: open -> closed ___ Python tracker <http://bugs.python.org/i

[issue28177] Compilation failure on Debian 4

2016-09-15 Thread Benjamin Peterson
Benjamin Peterson added the comment: 3.5 probably works. On Thu, Sep 15, 2016, at 22:21, David wrote: > > David added the comment: > > Thanks. > > What is the last official version of Python which does support GCC > versions > < 4.3 ? > > On Fri, Sep 16, 2

[issue28177] Compilation failure on Debian 4

2016-09-15 Thread Benjamin Peterson
Benjamin Peterson added the comment: We don't support GCC versions < 4.3 anymore. -- nosy: +benjamin.peterson resolution: -> wont fix status: open -> closed ___ Python tracker <http://bugs.pyth

[issue28119] Explicit null dereferenced in formatter_unicode.c

2016-09-13 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think that should take care of it (and also possible double-frees I noticed)? -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue28

[issue28131] assert statements missed when loaded by zipimporter

2016-09-13 Thread Benjamin Peterson
Benjamin Peterson added the comment: lgtm -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue28131> ___ ___ Python-bugs-list mailin

[issue28055] pyhash's siphash24 assumes alignment of the data pointer

2016-09-13 Thread Benjamin Peterson
Benjamin Peterson added the comment: Here's a patch that requires 8-byte alignment. It almost completely works except that on ABIs with 32-bit pointers, unicode objects can have their data pointers aligned at only 4-bytes. Perhaps we can get away with requiring only 4-byte alignment on 3

[issue28092] Build failure for 3.6 on Centos 5.11

2016-09-12 Thread Benjamin Peterson
Benjamin Peterson added the comment: On Mon, Sep 12, 2016, at 10:34, Łukasz Langa wrote: > > Łukasz Langa added the comment: > > Benjamin, what's the rationale behind switching those to inline > functions? Does it improve runtime performance or build speed? If not, I > d

[issue28092] Build failure for 3.6 on Centos 5.11

2016-09-11 Thread Benjamin Peterson
Benjamin Peterson added the comment: GCC 4.3 was released in March 2008, so I think we are within our rights to drop support for older toolchains. -- ___ Python tracker <http://bugs.python.org/issue28

[issue28055] pyhash's siphash24 assumes alignment of the data pointer

2016-09-09 Thread Benjamin Peterson
Benjamin Peterson added the comment: I believe the unaligned memory access configure check is supposed to prevent siphash from being used, so we might look into why that's not working. IMO, though, we should just require alignment for the argument to _PyHash_Bytes. It's private

[issue28051] Typo and broken links in page "What's New In Python 3.5"

2016-09-09 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> fixed status: open -> closed ___ Python tracker <http://bugs.python.org/issue28051> ___ ___ Python-bugs-

[issue27350] Compact and ordered dict

2016-09-09 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> fixed status: open -> closed ___ Python tracker <http://bugs.python.org/issue27350> ___ ___ Python-bugs-

[issue25856] The __module__ attribute of non-heap classes is not interned

2016-09-08 Thread Benjamin Peterson
Benjamin Peterson added the comment: I'm not too worried about slowing down __module__ especially since it's not any slower for heap types or types in builtins. On Thu, Sep 8, 2016, at 14:39, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > This is w

[issue25856] The __module__ attribute of non-heap classes is not interned

2016-09-08 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think it's better not write into the type dict in a getter. You might just use PyUnicode_InternFromString every time. FWIW, __name__ also has this behavior. -- ___ Python tracker <http://bugs.py

[issue28017] bluetooth.h on big endian needs GNU C extensions

2016-09-08 Thread Benjamin Peterson
Benjamin Peterson added the comment: stc99 means "C99 + GCC extensions that aren't incompatible with the standard". gnuc99 means "sort of C99 with whatever GNU weirdness" On Thu, Sep 8, 2016, at 11:25, Christian Heimes wrote: > > Christian Heimes added the c

[issue28017] bluetooth.h on big endian needs GNU C extensions

2016-09-08 Thread Benjamin Peterson
Benjamin Peterson added the comment: Hmm, I prefer to compile with stdc99. I wonder if we should consider this (presumably quite old) bluetooth.h to not exist if it doesn't work with c99. On Thu, Sep 8, 2016, at 02:49, Christian Heimes wrote: > > Christian Heimes added the comme

[issue28013] PPC64 Fedora socket and ssl compile failure

2016-09-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: It's strange because it seems to imply the system headers are syntatically invalid. -- ___ Python tracker <http://bugs.python.org/is

[issue25856] The __module__ attribute of non-heap classes is not interned

2016-09-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: I don't think it can be NULL either. On Wed, Sep 7, 2016, at 11:36, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > Indeed, the PyDict_Check() check can be omitted. > > -- > > ___

[issue25856] The __module__ attribute of non-heap classes is not interned

2016-09-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: I don't understand why you need to check the validity of tp_dict at all. We generally assume it's a dict. -- ___ Python tracker <http://bugs.python.o

[issue25856] The __module__ attribute of non-heap classes is not interned

2016-09-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: I don't understand this code: type->tp_dict && PyDict_Check(type->tp_dict) since the code explicitly assume it's not NULL and access it as a dict earlier in the function -- nosy: +benjamin.peterson __

[issue27928] Add hashlib.scrypt

2016-09-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: PEP 466 is explicitly not blanket approval for backporting All The Things to 2.7. The only justification for pbkdf2 in PEP 466 is to "lower the barriers to secure password storage and checking in Python 2 server applications". While scrypt is prob

[issue27928] Add hashlib.scrypt

2016-09-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: Why are we adding scrypt and not argon2 anyway? On Wed, Sep 7, 2016, at 03:25, Christian Heimes wrote: > > Christian Heimes added the comment: > > Benjamin, what's your take on Alex's suggestion? > > gutworth: Alex_Gaynor ha

[issue27570] Avoid memcpy(. . ., NULL, 0) etc calls

2016-09-06 Thread Benjamin Peterson
Benjamin Peterson added the comment: Sorry I missed this. The changes which I didn't already make look good. :) -- ___ Python tracker <http://bugs.python.org/is

[issue27987] obmalloc's 8-byte alignment causes undefined behavior

2016-09-06 Thread Benjamin Peterson
New submission from Benjamin Peterson: ubsan complains about unaligned access when structs include "long double". An example error: runtime error: member access within misaligned address 0x7f77dbba9798 for type 'struct CDataObject', which requires 16 byte alignment Thi

[issue17884] Try to reuse stdint.h types like int32_t

2016-09-06 Thread Benjamin Peterson
Benjamin Peterson added the comment: Thank you all for your advice. The buildbots seem to have survived the removal of conditional includes of . I've also replaced most of the Python compatibility aliases with the standard ones. Closing this issue. -- resolution: -> fixe

[issue17884] Try to reuse stdint.h types like int32_t

2016-09-06 Thread Benjamin Peterson
Benjamin Peterson added the comment: In 3.6, I just deprecated support for platforms without "long long". https://bugs.python.org/issue27961 "deprecated" is a strong word because I couldn't actually find a modern Python version that compiles without it. I'm info

[issue27961] remove support for platforms without "long long"

2016-09-05 Thread Benjamin Peterson
Benjamin Peterson added the comment: MSVC 2008 (at least) is documented to have "long long", too. https://msdn.microsoft.com/en-us/library/s3f49ktz(v=vs.90).aspx In fact, after this patch, I'm probably going to go s/PY_LONG

[issue27961] remove support for platforms without "long long"

2016-09-05 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- keywords: +patch stage: -> patch review Added file: http://bugs.python.org/file44384/longlong.patch ___ Python tracker <http://bugs.python.org/issu

[issue27961] remove support for platforms without "long long"

2016-09-05 Thread Benjamin Peterson
New submission from Benjamin Peterson: Neither Python 2.7 nor 3.3+ compile without HAVE_LONG_LONG, so effectively this is already completely unsupported. Let's completely dump it in 3.6. -- components: Interpreter Core messages: 274473 nosy: benjamin.peterson priority: normal sev

[issue27956] optimize dict_traverse a bit

2016-09-05 Thread Benjamin Peterson
New submission from Benjamin Peterson: dict_traverse shows up a lot on statistical profiles of Python programs. This is not surprising since Python programs have lots of dicts. There isn't a huge amount of room for optimization here, but we can avoid some memory indirection. This patch

[issue27811] _PyGen_Finalize() should not fail with an exception

2016-09-05 Thread Benjamin Peterson
Benjamin Peterson added the comment: Thank you, Armin. -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue27811> ___ ___ Python-bug

[issue27783] potential use of unitialized memory in operator.methodcaller

2016-08-16 Thread Benjamin Peterson
New submission from Benjamin Peterson: Thomas E Hybel reports: This vulnerability exists in /Modules/_operator.c in the function methodcaller_new. Here is the problematic code: mc = PyObject_GC_New(methodcallerobject, &methodcaller_type); if (mc == NULL) return

[issue27774] Py_DECREF on a non-owned object in _sre

2016-08-15 Thread Benjamin Peterson
New submission from Benjamin Peterson: Thomas E Hybel reports: This vulnerability exists in the function _sre_SRE_Match_groupdict_impl which resides in the /Modules/_sre.c file. The problem is that the code calls Py_DECREF(key); without having done a corresponding Py_INCREF on the key. Here&#

[issue27773] Excessive Py_XDECREF in the ssl module:

2016-08-15 Thread Benjamin Peterson
New submission from Benjamin Peterson: Thomas E. Hybel reports: This vulnerability exists in the function newPySSLSocket in /Modules/_ssl.c. The problem is that Py_XDECREF is called on an object, self->server_hostname, which isn't owned anymore. The code looks like this:

[issue27760] integer overflow in binascii.b2a_qp

2016-08-13 Thread Benjamin Peterson
New submission from Benjamin Peterson: Thomas E Hybel reports: This vulnerability resides in /Modules/binascii.c in the function binascii_b2a_qp_impl. The problem is that the integer variable "odatalen" can overflow to become a small number. The function binascii_b2a_qp_impl qp-enco

[issue27754] Changing the meaning of bool.__invert__

2016-08-13 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> rejected status: open -> closed ___ Python tracker <http://bugs.python.org/issue27754> ___ ___ Python-bugs-

[issue27758] integer overflow in the _csv module's join_append_data function

2016-08-13 Thread Benjamin Peterson
New submission from Benjamin Peterson: Thomas E Hybel on PSRT reports: This vulnerability is an integer overflow leading to a heap buffer overflow. I have attached a proof-of-concept script below. The vulnerability resides in the Modules/_csv.c file, in the join_append and join_append_data

[issue27655] [Patch] Don't require presence of POLLPRI

2016-08-01 Thread Benjamin Peterson
Benjamin Peterson added the comment: Are you planning on sending us patches to make Python compile without open(2)? Putting #ifdef around various constants is one thing but it seems like this could become quite invasive. -- ___ Python tracker

[issue27655] [Patch] Don't require presence of POLLPRI

2016-08-01 Thread Benjamin Peterson
Benjamin Peterson added the comment: Why do you remove the flag rather than just making it a noop? -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue27

[issue27369] [PATCH] Tests break with --with-system-expat and Expat 2.2.0

2016-07-13 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> fixed status: open -> closed ___ Python tracker <http://bugs.python.org/issue27369> ___ ___ Python-bugs-

[issue27301] Incorrect return codes in compile.c

2016-06-14 Thread Benjamin Peterson
Benjamin Peterson added the comment: lgtm -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue27301> ___ ___ Python-bugs-list mailin

[issue27140] Opcode for creating dict with constant keys

2016-06-11 Thread Benjamin Peterson
Benjamin Peterson added the comment: Okay, I think it's fine then. However, you have a for loop in compiler_subkwargs which only executes once. -- ___ Python tracker <http://bugs.python.org/is

[issue27140] Opcode for creating dict with constant keys

2016-06-09 Thread Benjamin Peterson
Benjamin Peterson added the comment: Does this change break this function? def subtle(): one = {-0. : 'a', -1: 'b'} two = {0. : 'a', -1: 'b'} assert all(math.copysign(1, x) < 0 for x in one) assert any(math.copysign(1, x) > 0 for x i

[issue26415] Fragmentation of the heap memory in the Python parser

2016-06-06 Thread Benjamin Peterson
Benjamin Peterson added the comment: It seems to me a simpler solution would be allocate all nodes for a parse tree in an arena. -- ___ Python tracker <http://bugs.python.org/issue26

[issue27211] Heap corruption via Python 2.7.11 IOBase readline()

2016-06-03 Thread Benjamin Peterson
New submission from Benjamin Peterson: Guido Vranken on PSRT report: Python-2.7.11/Modules/_io/iobase.c iobase_readline(): 531 old_size = PyByteArray_GET_SIZE(buffer); 532 PyByteArray_Resize(buffer, old_size + PyBytes_GET_SIZE(b)); 533 memcpy(PyByteArray_AS_STRING

[issue27185] Clarify Test Coverage for the String Module (test_pep292 is not easily discoverable)

2016-06-02 Thread Benjamin Peterson
Benjamin Peterson added the comment: On Thu, Jun 2, 2016, at 18:28, Martin Panter wrote: > > Martin Panter added the comment: > > FWIW I doubt Git is any better at this than Mercurial: > <https://github.com/python/cpython/blame/master/Lib/test/test_string.py#L190> >

[issue27185] Clarify Test Coverage for the String Module (test_pep292 is not easily discoverable)

2016-06-02 Thread Benjamin Peterson
Benjamin Peterson added the comment: We should be able to commit it now. git blame can usually figure out this stuff post facto. On Thu, Jun 2, 2016, at 13:54, R. David Murray wrote: > > R. David Murray added the comment: > > Benjamin: meaning we should wait for git to merge it,

[issue27185] Clarify Test Coverage for the String Module (test_pep292 is not easily discoverable)

2016-06-02 Thread Benjamin Peterson
Benjamin Peterson added the comment: I'm not too concerned about that. git can handle it well, which we will have soon. On Thu, Jun 2, 2016, at 12:50, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > This is not so easy. After adding all the tests from te

[issue27185] Increase Test Coverage for the String Module

2016-06-02 Thread Benjamin Peterson
Benjamin Peterson added the comment: It probably makes sense to move test_pep292.py tests into test_string.py. Test files named after peps are not very helpful. -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue27

[issue23116] Python Tutorial 4.7.1: Improve ask_ok() to cover more input values

2016-06-02 Thread Benjamin Peterson
Benjamin Peterson added the comment: I think the patch is okay except for the use of "-=" instead of the more verbose version. -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.o

[issue25731] Assigning and deleting __new__ attr on the class does not allow to create instances of this class

2016-05-28 Thread Benjamin Peterson
Benjamin Peterson added the comment: I'll have to think about how to fix this while maintaining compatiblity with obscure cases like above. -- ___ Python tracker <http://bugs.python.org/is

[issue27135] nested list produced with multiplication is linked to the same list

2016-05-26 Thread Benjamin Peterson
Benjamin Peterson added the comment: That's just how Python works. https://docs.python.org/3/faq/programming.html#how-do-i-create-a-multidimensional-list -- nosy: +benjamin.peterson resolution: -> not a bug status: open -> closed ___ Pyt

[issue27100] Attempting to use class with both __enter__ & __exit__ undefined yields __exit__ attribute error

2016-05-23 Thread Benjamin Peterson
Benjamin Peterson added the comment: I don't completely understand. If you get an AttributeError for __enter__, will you think only an __enter__ is required? -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/is

[issue21199] Python on 64-bit Windows uses signed 32-bit type for read length

2016-05-15 Thread Benjamin Peterson
Benjamin Peterson added the comment: Fixing seems fine with me. -- ___ Python tracker <http://bugs.python.org/issue21199> ___ ___ Python-bugs-list mailin

[issue26989] error in installation of ez_setup.py

2016-05-09 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> not a bug status: open -> closed ___ Python tracker <http://bugs.python.org/issue26989> ___ ___ Pyth

[issue26813] Wrong Japanese translation of "Adverb" on Documentation

2016-04-20 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> third party status: open -> closed ___ Python tracker <http://bugs.python.org/issue26813> ___ ___ Pyth

[issue26751] Possible bug in sorting algorithm

2016-04-16 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> not a bug status: open -> closed ___ Python tracker <http://bugs.python.org/issue26751> ___ ___ Pyth

[issue25731] Assigning and deleting __new__ attr on the class does not allow to create instances of this class

2016-04-16 Thread Benjamin Peterson
Benjamin Peterson added the comment: I believe the correct behavior is actually Traceback (most recent call last): File "", line 1, in File "bar.py", line 7, in C() TypeError: foo.A.__new__(C) is not safe, use foo.B.__new__() This is because A comes before B in

[issue26644] SSLSocket.recv(-1) triggers SystemError

2016-03-26 Thread Benjamin Peterson
Benjamin Peterson added the comment: Thanks for the explanation. Your patch lgtm. On Sat, Mar 26, 2016, at 15:01, Martin Panter wrote: > > Martin Panter added the comment: > > Socket objects aren’t exactly file-like. Plain non-SSL sockets don’t even > have read() methods. >

[issue26644] SSLSocket.recv(-1) triggers SystemError

2016-03-26 Thread Benjamin Peterson
Benjamin Peterson added the comment: Is this what other file-like objects do with negatives sizes? -- nosy: +benjamin.peterson ___ Python tracker <http://bugs.python.org/issue26

[issue19450] Bug in sqlite in Windows binaries

2016-03-14 Thread Benjamin Peterson
Benjamin Peterson added the comment: Let's make Windows use the same version as the Mac installer. -- assignee: benjamin.peterson -> steve.dower ___ Python tracker <http://bugs.python.org

[issue12736] Request for python casemapping functions to use full not simple casemaps per Unicode's recommendation

2016-03-10 Thread Benjamin Peterson
Benjamin Peterson added the comment: The full case mappings do not preserve normalization form. >>> for c in 'ΰ'.upper().lower(): print(unicodedata.name(c)) ... GREEK SMALL LETTER UPSILON COMBINING DIAERESIS COMBINING ACUTE ACCENT >>> unicodedata.normalize('

[issue26492] Exhausted array iterator should left exhausted

2016-03-07 Thread Benjamin Peterson
Benjamin Peterson added the comment: Can you add just one patch to seq_test.py? -- ___ Python tracker <http://bugs.python.org/issue26492> ___ ___ Python-bug

[issue25939] _ssl.enum_certificates() fails with ERROR_ACCESS_DENIED if python.exe run with low integrity level

2016-02-17 Thread Benjamin Peterson
Benjamin Peterson added the comment: The patch itself seems fine, so I committed that. It doesn't seem like how best to test this has been figured out, so leaving the issue open. -- nosy: +benjamin.peterson resolution: fixed -> stage: resolved -> status: clo

<    5   6   7   8   9   10   11   12   13   14   >