[issue12075] python3.2 memory leak when reloading class with attributes

2013-06-30 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.4 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12075 ___ ___

[issue11945] Adopt and document consistent semantics for handling NaN values in containers

2013-06-30 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.4 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11945 ___ ___

[issue14507] Segfault with deeply nested starmap calls

2013-06-30 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.4 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14507 ___ ___

[issue12211] Better document math.copysign behavior.

2013-06-30 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- versions: +Python 3.4 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12211 ___ ___

[issue16809] Tk 8.6.0 introduces TypeError. (Tk 8.5.13 works)

2013-06-30 Thread Arfrever Frehtes Taifersar Arahesis
Arfrever Frehtes Taifersar Arahesis added the comment: Please commit the full patch in all active branches. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16809 ___

[issue18329] for line in socket.makefile() speed degradation

2013-06-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: 3.4 have same performance as 3.3. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18329 ___ ___

[issue18328] Use after free in pystate.c

2013-06-30 Thread Charles-François Natali
Charles-François Natali added the comment: Well, tstate is freed, but is not used afterwards, it's just comparing the pointer against the TLS. -- nosy: +neologix ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18328

[issue11126] Wave.py does not always write proper length in header

2013-06-30 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- nosy: +serhiy.storchaka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11126 ___ ___

[issue14507] Segfault with deeply nested starmap calls

2013-06-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: This looks as a duplicate of issue14010. -- nosy: +serhiy.storchaka ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14507 ___

[issue11126] Wave.py does not always write proper length in header

2013-06-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: I don't see anything wrong in current code. In first alternation data is an array of sampwidth-sized items and the number of written bytes is len(data) * self._sampwidth. In second alternation data is raw bytes object and the number of written bytes is just

[issue18328] Use after free in pystate.c

2013-06-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Seems it is not possible to write a test for this. -- nosy: +serhiy.storchaka stage: test needed - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18328

[issue18178] Redefinition of malloc(3) family of functions at build time

2013-06-30 Thread koobs
koobs added the comment: I've added a new FreeBSD 10.0-CURRENT buildbot to the pool (thanks antoine) that reproduces the issue and should provide sufficient coverage for testing the proposed patch: http://buildbot.python.org/all/buildslaves/koobs-freebsd10 I'll upgrade the FreeBSD 9-STABLE

[issue18244] singledispatch: When virtual-inheriting ABCs at distinct points in MRO, composed MRO is dependent on haystack ordering

2013-06-30 Thread Łukasz Langa
Łukasz Langa added the comment: Having all information in place, I think it's acceptable for both of us to implement preference for explicit registration, leaving both ways of implicit registration as equally binding. The latter is future proof in the sense that if we change our minds later,

[issue4199] add shorthand global and nonlocal statements

2013-06-30 Thread Gregory P. Smith
Gregory P. Smith added the comment: Closing and rejecting based on said discussion. http://mail.python.org/pipermail/python-dev/2013-June/127143.html -- nosy: +gregory.p.smith resolution: - rejected status: open - closed ___ Python tracker

[issue18305] [patch] Fast sum() for non-numbers

2013-06-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Looks like this bug is CPython-specific, others (Jython, IronPython...) don't have it, so people will move code that depends on the internal optimization to other pythons that DO have it. :) I don't know about IronPython, but Jython and PyPy have same

[issue18331] runpy.run_path gives functions with corrupted .__globals__

2013-06-30 Thread Drekin
New submission from Drekin: Let's have a simple script test.py: def f(): return x x = 2 print(f()) Now if we try to run it via runpy.run_path, we get the following: import runpy g = runpy.run_path(test.py) 2 g[f]() is None True g[x] is 2 True g[f].__globals__[x] is None True Is

[issue18328] Use after free in pystate.c

2013-06-30 Thread Christian Heimes
Christian Heimes added the comment: I think it's unsafe. The address of a pointer should not be used once the pointer has been freed. How about we reverse the order? At first we remove the key from TLS and then free the tstate. -- keywords: +patch Added file:

[issue18328] Use after free in pystate.c

2013-06-30 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: LGTM. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18328 ___ ___ Python-bugs-list mailing list

[issue18331] runpy.run_path gives functions with corrupted .__globals__

2013-06-30 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- nosy: +ncoghlan ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18331 ___ ___ Python-bugs-list

[issue18038] Unhelpful error message on invalid encoding specification

2013-06-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset 19bc00996e74 by R David Murray in branch '3.3': #18038: Use non-deprecated assert names in tests. http://hg.python.org/cpython/rev/19bc00996e74 New changeset 29e7f6a2dc0d by R David Murray in branch 'default': Null merge #18038: Use non-deprecated

[issue18244] singledispatch: When virtual-inheriting ABCs at distinct points in MRO, composed MRO is dependent on haystack ordering

2013-06-30 Thread Łukasz Langa
Łukasz Langa added the comment: Here's an improved patch which doesn't copy data between lists in `_c3_mro()` so much. -- Added file: http://bugs.python.org/file30735/issue18244.diff ___ Python tracker rep...@bugs.python.org

[issue18332] _posix_listdir may leak FD

2013-06-30 Thread Christian Heimes
New submission from Christian Heimes: Under rare circumstances listdir() could leak a FD: - HAVE_FDOPENDIR is defined - dup(fd) succeeds - fdopendir() fails and sets dirp to NULL - if (dirp == NULL) goto exit - the dupped fd isn't closed because exit just handles dirp != NULL. Proposed fix:

[issue18331] runpy.run_path gives functions with corrupted .__globals__

2013-06-30 Thread Richard Oudkerk
Richard Oudkerk added the comment: When modules are garbage collected the associated globals dict is purged -- see #18214. This means that all values (except __builtins__) are replaced by None. To work around this run_path() apparently returns a *copy* of the globals dict which was created

[issue18333] Memory leak in _pickle.c:Unpickler_set_memo()

2013-06-30 Thread Christian Heimes
New submission from Christian Heimes: Unpickler_set_memo() has a memory leak when it is called with an empty dictionariy as argument - PyDict_Check(obj) is true - PyDict_Size(obj) returns 0 - _Unpickler_NewMemo(new_memo_size) calls PyMem_MALLOC(0) - PyMem_MALLOC(0) returns a valid pointer

[issue18332] _posix_listdir may leak FD

2013-06-30 Thread Richard Oudkerk
Richard Oudkerk added the comment: I think this is a duplicate of #17899. -- nosy: +sbt ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18332 ___

[issue18328] Use after free in pystate.c

2013-06-30 Thread Charles-François Natali
Charles-François Natali added the comment: I think it's unsafe. The address of a pointer should not be used once the pointer has been freed. Dereferencing a freed pointer is unsafe. A pointer is just an address, there's nothing inherently unsafe with comparing a pointer with a value. The

[issue18332] _posix_listdir may leak FD

2013-06-30 Thread Christian Heimes
Christian Heimes added the comment: You are right. -- resolution: - duplicate status: open - closed superseder: - os.listdir() leaks FDs if invoked on FD pointing to a non-directory ___ Python tracker rep...@bugs.python.org

[issue18189] IDLE Improvements: Unit test for Delegator.py

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: The test_delegator patches were useful for working out and testing the use of the gui resource. However, they are not appropriate for testing the Delegator class. It is a standalone class that has nothing to do with tkinter; in fact, the file has no imports.

[issue18189] IDLE Improvements: Unit test for Delegator.py

2013-06-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset a568a5426a16 by Terry Jan Reedy in branch '2.7': Issue 18189: remove unused methods in idlelib.Delegator.Delegator. http://hg.python.org/cpython/rev/a568a5426a16 New changeset 9d65716367c1 by Terry Jan Reedy in branch '3.3': Issue 18189: remove

[issue18224] pyvenv pydoc.py script causing AttributeErrors on Windows

2013-06-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset af837bf390d0 by Vinay Sajip in branch '3.3': Issue #18224: Removed pydoc script from created venv, as it causes problems on Windows and adds no value over and above python -m pydoc ... http://hg.python.org/cpython/rev/af837bf390d0 New changeset

[issue18288] Idle 2.7: Run Module does not set __file__

2013-06-30 Thread Roger Serwy
Roger Serwy added the comment: See issue8515. The patch was not applied to 2.7. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18288 ___ ___

[issue18318] Idle: stop depending on console output

2013-06-30 Thread Roger Serwy
Roger Serwy added the comment: This looks similar to issue13582 with the patch to redirect console writes to a GUI text box. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18318 ___

[issue18189] IDLE Improvements: Unit test for Delegator.py

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: I asked on the core-mentorship list about pydev test philosophy. I got useful answers from Nick and Antoine that can be summarized as We are pragmatic, not dogmatic. One may have to be a list member to read this link, but here it is.

[issue18189] IDLE Improvements: Unit test for Delegator.py

2013-06-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset 231c122b44b6 by Terry Jan Reedy in branch '2.7': Issue #18189: add test_delegator for Idle Delegator class. http://hg.python.org/cpython/rev/231c122b44b6 New changeset c7605471e8ae by Terry Jan Reedy in branch '3.3': Issue #18189: add

[issue18189] IDLE Improvements: Unit test for Delegator.py

2013-06-30 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- resolution: - fixed stage: needs patch - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18189 ___

[issue8515] idle Run Module (F5) does not set __file__ variable

2013-06-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset a958b7f16a7d by Terry Jan Reedy in branch '2.7': Issue #8515: Set __file__ when run file in IDLE. Backport 2c276d0553ff by http://hg.python.org/cpython/rev/a958b7f16a7d -- ___ Python tracker

[issue18288] Idle 2.7: Run Module does not set __file__

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: Thanks Roger, problem fixed. -- dependencies: +idle Run Module (F5) does not set __file__ variable resolution: - duplicate stage: test needed - committed/rejected status: open - closed ___ Python tracker

[issue13582] IDLE and pythonw.exe stderr problem

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: Todd, do you have a Mac to test this on? This patch treat sending messages to a widget as a backup option. In 18318 I propose we make Idle a true gui app, with all messages other than 'No tkinter' handled by the gui. Console writing, when available, would

[issue5308] cannot marshal objects with more than 2**31 elements

2013-06-30 Thread Christian Heimes
Christian Heimes added the comment: The macro W_SIZE at http://hg.python.org/cpython/file/dbdb6f7f9a1a/Python/marshal.c#l130 has introduced a reference leak at http://hg.python.org/cpython/file/dbdb6f7f9a1a/Python/marshal.c#l390 . Because W_SIZE returns in an error case the reference count of

[issue18318] Idle: stop depending on console output

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: The proposal here is to flip the roles of text console and graphics gui, rather than to indefinitely bandage the current roles. I would want that even with the patch for #13582 applied (which I hope can be done soon). --

[issue15767] add ModuleNotFoundError

2013-06-30 Thread Guido van Rossum
Guido van Rossum added the comment: Hey Brett, Sorry for reopening this issue. I am confused by the spec for ModuleNotFoundError. Look at this (in a pretty recent repo): $ ./python.exe Python 3.4.0a0 (default:8f22e03f5f07, Jun 27 2013, 08:49:16) [GCC 4.2.1 Compatible Apple Clang 4.0

[issue18244] singledispatch: When virtual-inheriting ABCs at distinct points in MRO, composed MRO is dependent on haystack ordering

2013-06-30 Thread Guido van Rossum
Guido van Rossum added the comment: Ok, let's do it. I just sent you a review of your latest code (admitting I don't actually follow the logic in full detail, so I'm mostly harping on tests and comments...). Regarding the PEP: feel free to update this. Clearly nobody read it this carefully

[issue17814] Popen.stdin/stdout/stderr documentation should mention object type

2013-06-30 Thread Nikolaus Rath
Changes by Nikolaus Rath nikol...@rath.org: -- keywords: +patch Added file: http://bugs.python.org/file30736/subprocess_rst.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17814 ___

[issue17814] Popen.stdin/stdout/stderr documentation should mention object type

2013-06-30 Thread Nikolaus Rath
Nikolaus Rath added the comment: patch attached. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17814 ___ ___ Python-bugs-list mailing list

[issue18331] Document that runpy.run_path and run_module copy the module globals

2013-06-30 Thread Nick Coghlan
Nick Coghlan added the comment: As Richard said, the __globals__ attributes of the functions are pointing at the real module dictionary, which may have been cleared when the temporary module was destroyed. However, I just checked the docs and they don't actually mention the fact that

[issue6181] Tkinter.Listbox several minor issues

2013-06-30 Thread Martin Panter
Changes by Martin Panter vadmium...@gmail.com: -- nosy: +vadmium ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6181 ___ ___ Python-bugs-list

[issue18334] type(name, bases, dict) does not call metaclass' __prepare__ attribute

2013-06-30 Thread Nikolaus Rath
New submission from Nikolaus Rath: When using the three parameter form of type to create a new class, and any of the base classes has a metaclass with a __prepare__ function, the __prepare__ function is not executed: class CustomMetaclass(type): ... @classmethod ...

[issue18334] type(name, bases, dict) does not call metaclass' __prepare__ attribute

2013-06-30 Thread R. David Murray
R. David Murray added the comment: Intentional is not perhaps the exactly right term, but it is working as expected. There was a thread about this on python-dev (PEP 3115 compliant dynamic type creation and adding types.build_class for 3.3), that ultimately resulted in the addition of the

[issue18334] type(name, bases, dict) does not call metaclass' __prepare__ attribute

2013-06-30 Thread Nick Coghlan
Nick Coghlan added the comment: I think we should actually go further, and explicitly defer to http://docs.python.org/3/library/types#dynamic-type-creation for dynamic type creation. Type shouldn't be called with arbitrary bases any more, precisely *because* doing so breaks __prepare__

[issue18334] type(name, bases, dict) does not call metaclass' __prepare__ attribute

2013-06-30 Thread Nikolaus Rath
Nikolaus Rath added the comment: In that cases, maybe type(name, cls, clsdict) should actually raise an error if there's a metaclass with __prepare__ involved? Presumably that would break only code that was already broken, but it would convert previously hidden behavioral bugs into an

[issue7136] Idle File Menu Option Improvement

2013-06-30 Thread Todd Rovito
Todd Rovito added the comment: PING It has been a month since Roger's last comment on the patch looking good, can somebody please commit or post feedback. Thanks. -- nosy: +terry.reedy ___ Python tracker rep...@bugs.python.org

[issue13582] IDLE and pythonw.exe stderr problem

2013-06-30 Thread Todd Rovito
Todd Rovito added the comment: Yes I have a Mac and I am glad to help, so I gave it a test run tonight. The first thing I did was apply the patch then I ran idle from the console like so: ./python.exe Lib/idlelib/idle.py For testing I used a simple print command to print to stderr:

[issue13582] IDLE and pythonw.exe stderr problem

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: Print in the user process goes to shell window. You need to stimulate (or just add) print or warn in the idle process, which normally goes to console, or nowhere. It is hard (intentionally, I am sure) to dynamically manipulate idle process code. Roger said

[issue7136] Idle File Menu Option Improvement

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: I am planning to commit. PS. Shorter names that include '27', '33', etc, are easier to work with ;-). -- assignee: roger.serwy - terry.reedy ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7136

[issue7136] Idle File Menu Option Improvement

2013-06-30 Thread Roundup Robot
Roundup Robot added the comment: New changeset 26ef5d5d5c3e by Terry Jan Reedy in branch '2.7': Issue #7136: In the Idle File menu, New Window is renamed New File. http://hg.python.org/cpython/rev/26ef5d5d5c3e New changeset c39ddff53694 by Terry Jan Reedy in branch '3.3': Issue #7136: In the

[issue7136] Idle File Menu Option Improvement

2013-06-30 Thread Terry J. Reedy
Terry J. Reedy added the comment: For some reason, the idlelib/help.txt was reformatted with double indents (not sure I like this) for 3.4 but not 3.3. So parts of the patch against 3.4 would not apply to 3.3, which must be patched first. And the merge to 3.4 likewise failed for two files. We

[issue7136] Idle File Menu Option Improvement

2013-06-30 Thread Terry J. Reedy
Changes by Terry J. Reedy tjre...@udel.edu: -- resolution: - fixed stage: commit review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7136 ___

[issue18244] singledispatch: When virtual-inheriting ABCs at distinct points in MRO, composed MRO is dependent on haystack ordering

2013-06-30 Thread Gabriel Genellina
Changes by Gabriel Genellina ggenell...@gmail.com: -- nosy: +ggenellina ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18244 ___ ___

[issue18335] Add textwrap.dedent, .indent, as str methods.

2013-06-30 Thread Terry J. Reedy
New submission from Terry J. Reedy: To end proposals for new syntax to do what they do for triple-quoted strings. Nick Coghlan gave reasons as follows: run time cost small, can be optimized away, would be used more than some other string methods.

[issue18318] Idle: stop depending on console output

2013-06-30 Thread Gabriel Genellina
Changes by Gabriel Genellina ggenell...@gmail.com: -- nosy: +ggenellina ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18318 ___ ___

[issue13582] IDLE and pythonw.exe stderr problem

2013-06-30 Thread Gabriel Genellina
Changes by Gabriel Genellina ggenell...@gmail.com: -- nosy: +ggenellina ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13582 ___ ___

[issue18335] Add textwrap.dedent, .indent, as str methods.

2013-06-30 Thread SpaghettiToastBook
Changes by SpaghettiToastBook spaghettitoastb...@gmail.com: -- nosy: +SpaghettiToastBook ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18335 ___