[issue16177] Typing left parenthesis in IDLE causes intermittent Cocoa Tk crash on OS X

2014-10-07 Thread Ned Deily
Ned Deily added the comment: Tom, thanks for the detailed analysis. It seems pretty clear that this is not a Python problem and there's really nothing we can do about it. It would be great if you would be willing to open an issue on the Tcl/Tk project's issue tracker so that they are aware o

[issue16177] Typing left parenthesis in IDLE causes intermittent Cocoa Tk crash on OS X

2014-10-07 Thread Tom Goddard
Tom Goddard added the comment: More testing shows that this Mac Tk crash with dual displays only happens when the second display is partly or entirely above the primary display in the Mac display system preferences. An attempt to show the tooltip on the second display above the top of the pri

[issue16177] Typing left parenthesis in IDLE causes intermittent Cocoa Tk crash on OS X

2014-10-07 Thread Tom Goddard
Tom Goddard added the comment: I've seen this crash about 50 times in the UCSF Chimera molecular visualization package, same traceback, and it is caused when a tooltip is raised, but not from IDLE. The key observation is that it only happens on dual display systems where the second display is

[issue22524] PEP 471 implementation: os.scandir() directory scanning function

2014-10-07 Thread STINNER Victor
STINNER Victor added the comment: Hi Ben, I started to review your patch, sorry for the delay :-( It's convinient to have the patch on Rietveld to comment it inline. I didn't expect so much C code. The posixmodule.c is really huge. Well, it's just the longest C file of Python 3.5. Your patch

[issue22462] Modules/pyexpat.c violates PEP 384

2014-10-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: Here is an updated patch with a test. -- Added file: http://bugs.python.org/file36833/expat_traceback.patch ___ Python tracker ___ _

[issue22576] ftplib documentation gives a wrong argument name for storbinary

2014-10-07 Thread Derek Kurth
New submission from Derek Kurth: The Python 3 documentation for ftplib gives the storbinary method signature as: FTP.storbinary(cmd, file, blocksize=8192, callback=None, rest=None) However, the parameter named "file" is actually named "fp" in the code, so if you do something like this: ftp.st

[issue22477] GCD in Fractions

2014-10-07 Thread Stefan Behnel
Stefan Behnel added the comment: > it might be worth at least considering how a 'one or more parameter' gcd > compares on performance grounds with a two parameter one. There shouldn't be a difference in practice. The bulk of the work is in the algorithm that finds the GCD of two numbers, and f

[issue22534] bsddb memory leak with MacPorts bdb 4.6

2014-10-07 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +jcea ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue22575] bytearray documentation confuses string for unicode objects

2014-10-07 Thread Martijn Pieters
New submission from Martijn Pieters: The Python 2 version of the bytearray() documentation appears to be copied directly from its Python 3 counterpart and states that when passing in a string an encoding is required: * If it is a string, you must also give the encoding (and optionally, errors)

[issue22297] 2.7 json encoding broken for enums

2014-10-07 Thread Edward O
Edward O added the comment: The arguments for fixing: * int subclasses overriding str is a very common usecase for enums (so much so that it was added to stdlib in 3.4). * json supporting a standard type of a subsequent python version, though not mandatory, would be beneficial to Py2/Py3 comp

[issue12067] Doc: remove errors about mixed-type comparisons.

2014-10-07 Thread Andy Maier
Andy Maier added the comment: Just wanted to say that i will continue working on this, working in the comments made so far... Andy -- ___ Python tracker ___

[issue18216] gettext doesn't check MO versions

2014-10-07 Thread Aaron Hill
Aaron Hill added the comment: That sounds good. Should a warning be thrown for an unexpected minor revision? -- ___ Python tracker ___ ___

[issue22570] Better stdlib support for Path objects

2014-10-07 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti type: -> enhancement ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue22570] Better stdlib support for Path objects

2014-10-07 Thread Brett Cannon
Brett Cannon added the comment: I think I'm missing something here because the idea of doing `path = str(path)` at the API boundary for an old function to support both Path and str objects for paths seems fairly minimal. Only when manipulating a path is wanting a Path object going to come up,

[issue18161] call fchdir if subprocess.Popen(cwd=integer|fileobject)

2014-10-07 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue22574] super() and del in the same method leads to UnboundLocalError

2014-10-07 Thread Pierre-Antoine BRAMERET
Pierre-Antoine BRAMERET added the comment: Hi, Tanks for your clear answer. I find it surprising that "del" bounds the name locally, but with little more thinking, it is not... -- resolution: -> not a bug status: open -> closed ___ Python tracker

[issue22572] NoneType object is not iterable error when asyncio Server.close() called

2014-10-07 Thread R. David Murray
R. David Murray added the comment: Yes, documenting it at the beginning would be good. I haven't gotten to the end of the docs yet, I like to experiment as I go along :) -- ___ Python tracker

[issue7830] Flatten nested functools.partial

2014-10-07 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo type: enhancement -> performance ___ Python tracker ___ ___ Python-bugs-list mailing list U

[issue22568] Use of "utime" as variable name in Modules/posixmodule.c causes errors

2014-10-07 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue22574] super() and del in the same method leads to UnboundLocalError

2014-10-07 Thread Mark Dickinson
Mark Dickinson added the comment: So while the behaviour is surprising, the language is behaving as designed: the target of `del` is considered to be a local variable for the entire function definition. (In much the same way, the targets of simple assignments are considered local, so if you'

[issue22564] ssl: post-commit review of the new memory BIO API

2014-10-07 Thread STINNER Victor
STINNER Victor added the comment: > For total cleanness maybe the constructor should raise a TypeError if > server_hostname is passes as a bytes. Oh. So there are two attributes? SSLSocket.server_hostname and SSLSocket._sslobj.server_hostname? The constructor should make sure that both are cons

[issue22572] NoneType object is not iterable error when asyncio Server.close() called

2014-10-07 Thread STINNER Victor
STINNER Victor added the comment: Oh, I didn't notice that waiter_bug.py does nothing :-) I added "unittest.main()". With PYTHONASYNCIODEBUG=1, I get *two* errors, maybe we don't need to add more checks in debug mode. Again, maybe the debug mode should be better documented? https://docs.python

[issue18216] gettext doesn't check MO versions

2014-10-07 Thread Jakub Wilk
Jakub Wilk added the comment: The patch hardcodes 5 as version number in the exception message. The specifiction also says that "an unexpected minor revision number means that the file can be read but will not reveal its full contents, when parsed by a program that supports only smaller minor

[issue22572] NoneType object is not iterable error when asyncio Server.close() called

2014-10-07 Thread STINNER Victor
STINNER Victor added the comment: Maybe we should more checks in debug mode in the Server class? For example, loop.call_soon() raises an AssertionError if it is called from the "wrong" thread" in debug mode. -- ___ Python tracker

[issue22574] super() and del in the same method leads to UnboundLocalError

2014-10-07 Thread Pierre-Antoine BRAMERET
Pierre-Antoine BRAMERET added the comment: Sorry, I miscopied the last Traceback. Please find the following: Traceback (most recent call last): File "", line 1, in File "", line 4, in __init__ assert Foo UnboundLocalError: local variable 'Foo' referenced before assignment -- _

[issue22572] NoneType object is not iterable error when asyncio Server.close() called

2014-10-07 Thread STINNER Victor
STINNER Victor added the comment: > Using call_soon_threadsafe from an addCleanup in the _server method makes it > work for me. Maybe the documentation on thread safety should be improved? More warnings should be put in the documentation? https://docs.python.org/dev/library/asyncio-dev.html#

[issue22574] super() and del in the same method leads to UnboundLocalError

2014-10-07 Thread Pierre-Antoine BRAMERET
New submission from Pierre-Antoine BRAMERET: Hi, With the following code: class Base(object): pass class Foo(Base): def __init__(self): super(Foo,self).__init__() if False: del Foo I expect that Foo() would give me a Foo instance. Instead, it raises the following exception:

[issue22294] 2to3 consuming_calls: len, min, max, zip, map, reduce, filter, dict, xrange

2014-10-07 Thread Edward O
Changes by Edward O : -- nosy: +BreamoreBoy ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python

[issue22571] Remove import * recommendations and examples in doc?

2014-10-07 Thread Mark Dickinson
Mark Dickinson added the comment: I think it's fine to recommend using (for example) `>>> from decimal import *` at the command-line prompt when experimenting with a module. It's a quick way to get yourself into a state where you can easily experiment with that module and its features. That'

[issue12458] Tracebacks should contain the first line of continuation lines

2014-10-07 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' : -- stage: test needed -> needs patch versions: +Python 3.5 -Python 3.4 ___ Python tracker ___ ___ Pytho

[issue18119] urllib.FancyURLopener does not treat URL fragments correctly

2014-10-07 Thread karl
karl added the comment: OK I fixed the code. The issue is here https://hg.python.org/cpython/file/1e1c6e306eb4/Lib/urllib/request.py#l656 newurl = urlunparse(urlparts) Basically it reinjects the fragment in the new url. The fix is easy. if urlparts.fragment: urlpart