[issue17457] Unittest discover fails with namespace packages and builtin modules

2013-07-10 Thread Michael Foord
Michael Foord added the comment: I'd like to review this properly before committing it. I agree it solves a real problem and your new patch looks good. -- ___ Python tracker ___

[issue6742] Embedding python into shared library crash on AIX

2013-07-10 Thread Christian Heimes
Changes by Christian Heimes : -- status: open -> languishing ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue15859] PyUnicode_EncodeFSDefault win32 inconsistancy.

2013-07-10 Thread Christian Heimes
Christian Heimes added the comment: The code has changed considerable since you have created the patch. Is this still an issue for Python 3.3? -- nosy: +christian.heimes status: open -> languishing versions: +Python 3.4 ___ Python tracker

[issue2123] ctypes pointer not always keeping target alive

2013-07-10 Thread Christian Heimes
Changes by Christian Heimes : -- status: open -> languishing versions: +Python 3.3, Python 3.4 -Python 3.1, Python 3.2 ___ Python tracker ___ _

[issue18352] collections.Counter with added attributes are not deepcopied properly.

2013-07-10 Thread Vajrasky Kok
Vajrasky Kok added the comment: The question is whether we should give the freedom to user to add dynamic attribute to Counter object. Is this freedom has any practicality? Why do we want to add dynamic attributes to Counter object? Decimal object does not have this freedom. >>> from decimal

[issue15859] PyUnicode_EncodeFSDefault win32 inconsistancy.

2013-07-10 Thread STINNER Victor
STINNER Victor added the comment: > Is this still an issue for Python 3.3? Yes. -- ___ Python tracker ___ ___ Python-bugs-list mailin

[issue18421] Refactor call_with_frame() function of pyexpat.c

2013-07-10 Thread STINNER Victor
New submission from STINNER Victor: Modules/pyexpat.c contains a call_with_frame() function which uses many low-level attributes like tstate->c_profilefunc. I don't think that pyexpat.c is the best place for such function, it should be moved to Python/ceval.c. Except the call to XML_StopParser

[issue18408] Fixes crashes found by pyfailmalloc

2013-07-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4f730c045f5f by Victor Stinner in branch 'default': Issue #18408: Fix call_exc_trace(): if the traceback is NULL, use None when http://hg.python.org/cpython/rev/4f730c045f5f -- ___ Python tracker

[issue18360] Won't install. Keeps telling me DLL is missing.

2013-07-10 Thread Martin v . Löwis
Martin v. Löwis added the comment: I'm pretty sure the problem is the one reported in http://superuser.com/questions/478631/dll-could-not-be-run-for-msi-installers The solution/work-around is to give full access to Everyone in the Temp folder. Please report whether this works. -- ___

[issue18422] is_package missing so can't use -m

2013-07-10 Thread andrew cooke
New submission from andrew cooke: Using python 3.3, if I try to run __main__ I see this error: Traceback (most recent call last): File "/usr/local/lib/python3.3/runpy.py", line 140, in _run_module_as_main mod_name, loader, code, fname = _ge

[issue18422] is_package missing so can't use -m

2013-07-10 Thread Christian Heimes
Christian Heimes added the comment: You can't edit posts. :) I was going to ask how you are running __main__ but you were faster than me. -- assignee: -> brett.cannon nosy: +brett.cannon, christian.heimes type: -> behavior versions: +Python 3.4 ___

[issue18422] is_package missing so can't use -m

2013-07-10 Thread andrew cooke
andrew cooke added the comment: can't see how to edit posts, so adding as a comment, this is what triggers the bug: > PYTHONPATH=src python -m simplessl -- ___ Python tracker _

[issue15792] Fix compiler options for x64 builds on Windows

2013-07-10 Thread Jeremy Kloth
Jeremy Kloth added the comment: Just to note that, as it stands, these wrongly assigned options account for 28 of the 216 warnings (or 13%) currently emitted. This is just one easy step towards a warning-free 64-bit Windows build. It would be nice to get Win64 to be one of the warning-free pl

[issue18422] is_package missing so can't use -m

2013-07-10 Thread Brett Cannon
Brett Cannon added the comment: The solution from issue #18058 can't be backported because it would expose a new public API on the NamespaceLoader class. It would also introduce new functionality which would differ between Python 3.3.2 and Python 3.3.3 which can't really be classified as a bug

[issue18423] Document limitations on -m

2013-07-10 Thread andrew cooke
New submission from andrew cooke: Apparently the limited support for -m is standard behaviour - see http://bugs.python.org/issue18422 - but it's not documented at http://docs.python.org/3/using/cmdline.html#cmdoption-m That should say, somewhere, that it only applies to leaf modules and packag

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread Marco Buttu
New submission from Marco Buttu: The documentaion of sum(): Returns the sum of a sequence of numbers (NOT strings) plus the value of parameter 'start' (which defaults to 0). When the sequence is empty, returns start. A. According to the PEP-8 it should be: "Return the sum...", an

[issue18422] is_package missing so can't use -m

2013-07-10 Thread Barry A. Warsaw
Changes by Barry A. Warsaw : -- nosy: +barry ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue18417] urlopen() has a hidden default for its timeout argument

2013-07-10 Thread R. David Murray
R. David Murray added the comment: See also issue 4079, if you are concerned about timeouts in urllib. -- ___ Python tracker ___ ___ P

[issue18407] Fix compiler warnings in pythoncore for Win64

2013-07-10 Thread Jeremy Kloth
Jeremy Kloth added the comment: Added new patch that removes the duplicate changes from issue #15792 and comments the lone explicit cast. These changes fix 116 of the 216 warnings (54%!) for Win64. Together with issue #15792 brings the remaining count to 72. I am unsure if splitting the chan

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread R. David Murray
R. David Murray added the comment: Perhaps we could add something like "Also works, though possibly inefficiently, on any iterable whose elements support addition". The biggest part of the sphinx docs for this are about what to use instead, and that doesn't really seem appropriate for a docst

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread R. David Murray
Changes by R. David Murray : -- versions: +Python 3.4 -Python 3.1, Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue18402] Finding perl64

2013-07-10 Thread Martin v . Löwis
Martin v. Löwis added the comment: OTOH, perl is not a prerequisite in the first place for building Python with OpenSSL. Why do you think you need it? -- nosy: +loewis ___ Python tracker __

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread Ronald Oussoren
Ronald Oussoren added the comment: There's an annoyingly long discussion about sum() on python-ideas. IMHO the documentation should mention, as it does now, that sum is intended to be used with a sequence of numbers even it does work with most objects that support the + operator (such as by im

[issue18417] urlopen() has a hidden default for its timeout argument

2013-07-10 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: On Jul 10, 2013, at 05:53 AM, R. David Murray wrote: >Please see issue 14425 and then let us know if this is still valid. It's >been a while since I looked at the code and I no longer remember the details, >but I seemed confident in my conclusion at the time..

[issue18417] urlopen() has a hidden default for its timeout argument

2013-07-10 Thread R. David Murray
R. David Murray added the comment: OK, I reviewed the issue enough to remember: If socket.setdefaulttimeout is never called, then the default timeout is None (no timeout). Since socket.setdefaulttimeout is deprecated, the global default should always be None. Therefore, if you want to use t

[issue18417] urlopen() has a hidden default for its timeout argument

2013-07-10 Thread R. David Murray
Changes by R. David Murray : -- nosy: +facundobatista ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://ma

[issue18352] collections.Counter with added attributes are not deepcopied properly.

2013-07-10 Thread Olivier Gagnon
Olivier Gagnon added the comment: The dictionary and the set do not give the freedom to add dynamic attributes to them. I agree that the Counter should have the same behaviour. However, this will raise the same bug when we inherit from a Counter object. >>> class mylist(list): pass ... >>> l

[issue18423] Document limitations on -m

2013-07-10 Thread Brett Cannon
Changes by Brett Cannon : -- keywords: +easy stage: -> needs patch versions: +Python 3.3 ___ Python tracker ___ ___ Python-bugs-list

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread R. David Murray
R. David Murray added the comment: OK, so your vote is to leave the doc string alone (except for the PEP8 changes), right? -- ___ Python tracker ___

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread Ronald Oussoren
Ronald Oussoren added the comment: Yes, the docstring isn't meant to be exhaustive documentation. The manual is more exhaustive and, as you noted, already contains links to alternatives. -- ___ Python tracker

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread Ezio Melotti
Ezio Melotti added the comment: Currently sum() is intended to work with numbers, explicitly forbids strings (as noted in the docstring), but also works with other types (even though it's inefficient). If we want to document this, a possible wording might be: Returns the sum of a sequence

[issue18416] Move to absolute file paths for module.__file__

2013-07-10 Thread Ronald Oussoren
Ronald Oussoren added the comment: Isn't this because the first entry of sys.path is '' when python is started without a script? All other paths on sys.path are already absolute paths (tested with a relative path in $PYTHONPATH). If that's correct, just adding os.getcwd() instead of '' as the

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread Marco Buttu
Marco Buttu added the comment: By reading the Ronald's comment, I realized it is better to keep it simple, so I agree with him. The "extremely inefficient" reason seems to be less important (Python 3.3): $ python -m timeit -s "a=['a']*1; b=['b']*1; a+b" 1 loops, best of 3: 0.00

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread Ronald Oussoren
Ronald Oussoren added the comment: Appending a sequence of lists with sum is inefficient because it (currently) does a lot of copying, and that gets noticable when you sum a larger number of lists Note how using sum for add 200 lists is more than twice as long as adding 100 lists: ronald@gon

[issue18378] locale.getdefaultlocale() fails on Mac OS X with default language set to English

2013-07-10 Thread Martin v . Löwis
Martin v. Löwis added the comment: Why do you need the "getdefaultlocale" function in the first place? I'd advise against using it, precisely because it can trigger problems like this one. -- nosy: +loewis ___ Python tracker

[issue18378] locale.getdefaultlocale() fails on Mac OS X with default language set to English

2013-07-10 Thread Dmitry Jemerov
Dmitry Jemerov added the comment: I personally don't, but the function is used by Sphinx, which is what I was trying to get to work when I ran into this problem. -- ___ Python tracker _

[issue18324] set_payload does not handle binary payloads correctly

2013-07-10 Thread Vajrasky Kok
Vajrasky Kok added the comment: Here is the preliminary patch for email module to pass the test. -- nosy: +vajrasky Added file: http://bugs.python.org/file30884/set_payload_handles_binary_correctly.txt ___ Python tracker

[issue18378] locale.getdefaultlocale() fails on Mac OS X with default language set to English

2013-07-10 Thread R. David Murray
R. David Murray added the comment: Regardless of the resolution here, the use of getdefaultlocale could be reported as a bug on the sphinx tacker. -- nosy: +r.david.murray ___ Python tracker __

[issue18399] Fix grammar in comment in python.c

2013-07-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset c02656962b9c by R David Murray in branch '3.3': #18399: fix comment typo. http://hg.python.org/cpython/rev/c02656962b9c New changeset b583fd54c8d6 by R David Murray in branch 'default': Merge: #18399: fix comment typo. http://hg.python.org/cpython/r

[issue18399] Fix grammar in comment in python.c

2013-07-10 Thread R. David Murray
R. David Murray added the comment: Thanks, Andrew. -- nosy: +r.david.murray resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: +Python 3.3 ___ Python tracker __

[issue18324] set_payload does not handle binary payloads correctly

2013-07-10 Thread R. David Murray
R. David Murray added the comment: Thanks, but the patch is incorrect. The model consistently stores its data as surrogateescaped strings, and this assumption is baked in to other parts of the code. So the correct fix is to do the surrogateescape encoding at the time the payload is set. It

[issue18378] locale.getdefaultlocale() fails on Mac OS X with default language set to English

2013-07-10 Thread Martin v . Löwis
Martin v. Löwis added the comment: FWIW, I couldn't find any use of getdefaultlocale in any of the hg revisions (using hg grep) in https://bitbucket.org/birkenfeld/sphinx/ Instead, it's (probably) docutils, which has this code: locale_encoding = locale.getlocale()[1] or locale.getdefaultl

[issue18324] set_payload does not handle binary payloads correctly

2013-07-10 Thread Vajrasky Kok
Vajrasky Kok added the comment: I see. Thanks for the explanation. I'll do this patch if nobody is interested. -- ___ Python tracker ___ _

[issue18324] set_payload does not handle binary payloads correctly

2013-07-10 Thread R. David Murray
R. David Murray added the comment: If you want to work on it that would be great. Note that one of the things that is needed is a bunch more tests of setting various *kinds* of binary payload, including ones containing non-ascii data, and making sure the right thing happens when the payload i

[issue18416] Move to absolute file paths for module.__file__

2013-07-10 Thread Brett Cannon
Brett Cannon added the comment: That's exactly why it currently happens. What I would do is change importlib to just associate '' with os.getcwd() in FileFinder. That locks down where the module was found to an absolute path while still allowing '' to function as the cwd and be dynamically cal

[issue12735] request full Unicode collation support in std python library

2013-07-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: +Python 3.4 -Python 3.3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12731] python lib re uses obsolete sense of \w in full violation of UTS#18 RL1.2a

2013-07-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: +Python 3.4 -Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12734] Request for property support in Python re lib

2013-07-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: +Python 3.4 -Python 3.3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12733] Request for grapheme support in Python re lib

2013-07-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: +Python 3.4 -Python 3.3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue12728] Python re lib fails case insensitive matches on Unicode data

2013-07-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- versions: +Python 3.4 -Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4b3b87719e2c by R David Murray in branch '3.3': #18424: PEP8ify the tense of the sum docstring. http://hg.python.org/cpython/rev/4b3b87719e2c New changeset 38b42ffdf86b by R David Murray in branch 'default': Merge: #18424: PEP8ify the tense of the s

[issue18424] sum() does not return only the sum of a sequence of numbers + PEP8 reccomandation

2013-07-10 Thread R. David Murray
R. David Murray added the comment: Ok, pep8 changes committed. -- resolution: -> fixed stage: -> committed/rejected status: open -> closed type: -> behavior ___ Python tracker ___

[issue4079] new urllib2.Request 'timeout' attribute needs to have a default

2013-07-10 Thread R. David Murray
R. David Murray added the comment: Now we need a test :) -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http

[issue12681] unittest expectedFailure could take a message argument like skip does

2013-07-10 Thread R. David Murray
R. David Murray added the comment: Thanks, Adam. I'm afraid it may be a while before Michael (or anyone else) gets a chance to review it and think about the issue some more. -- ___ Python tracker

[issue18382] multiprocessing's overlapped PipeConnection issues on Windows 8

2013-07-10 Thread Walter Prins
Walter Prins added the comment: What's the process for volunteering a buildbot? Email python-dev? I *might* volunteer to set one up... -- ___ Python tracker ___ ___

[issue18116] getpass.unix_getpass() always fallback to sys.stdin

2013-07-10 Thread Roundup Robot
Roundup Robot added the comment: New changeset 70f55dc9d43f by R David Murray in branch 'default': #18116: getpass no longer always falls back to stdin. http://hg.python.org/cpython/rev/70f55dc9d43f -- nosy: +python-dev ___ Python tracker

[issue18116] getpass.unix_getpass() always fallback to sys.stdin

2013-07-10 Thread R. David Murray
R. David Murray added the comment: I played around with this for a bit, but I couldn't come up with any test improvements, or any way to test the bug that is being fixed. So I just committed it as is. Thanks, Serhiy. And thanks Vajrasky for giving it a try and figuring out some of the stuff

[issue18360] Won't install. Keeps telling me DLL is missing.

2013-07-10 Thread Dale Smith
Dale Smith added the comment: I got it! None of these alone actually worked. But it lead me to get it to work. I did several solutions at once. The three in combination that worked were getting this: http://www.howtogeek.com/howto/windows-vista/add-take-ownership-to-explorer-right-click-me

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

2013-07-10 Thread Ethan Furman
Changes by Ethan Furman : -- nosy: +ethan.furman ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue18382] multiprocessing's overlapped PipeConnection issues on Windows 8

2013-07-10 Thread R. David Murray
R. David Murray added the comment: What information there is is here: http://wiki.python.org/moin/BuildBot. Antoine Pitrou is the current buildbot "master" and will issue you a password once you are set up, if you decide to do this. You can also talk to us on the #python-dev irc channel. Wi

[issue18425] IDLE Unit test for IdleHistory.py

2013-07-10 Thread R. Jayakrishnan
New submission from R. Jayakrishnan: Continuing the IDLE unittest framework #15392, unit test for IdleHistory.py. This test depends on mockText and uses the patch by Terry at issue #18365. Because the mockText is still about to commit, first patch http://bugs.python.org/file30865/mock_text2.dif

[issue18416] Move to absolute file paths for module.__file__

2013-07-10 Thread Nick Coghlan
Nick Coghlan added the comment: Brett's plan sounds good to me. We should also check we make sure __main__.__file__ is always absolute. -- ___ Python tracker ___ ___

[issue10042] functools.total_ordering fails to handle NotImplemented correctly

2013-07-10 Thread Jim Jewett
Jim Jewett added the comment: > Since this is such an incredibly niche edge case > (the ordered comparison has to return NotImplemented > while __eq__ returns True), *and* the types are explicitly supposed to ordered, based on what is being tested > I remaining consistent with the existing b

[issue18422] is_package missing so can't use -m

2013-07-10 Thread andrew cooke
andrew cooke added the comment: in case anyone else ends up here through google... the problem described here is not related to the linked issue. it was just a missing `__init__.py` in the module (plus sucky error messages). the following works fine: . ├── README.md ├── src │   └── simplessl

[issue18425] IDLE Unit test for IdleHistory.py

2013-07-10 Thread Phil Webster
Changes by Phil Webster : -- nosy: +philwebster ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue18425] IDLE Unit test for IdleHistory.py

2013-07-10 Thread Todd Rovito
Changes by Todd Rovito : -- nosy: +Todd.Rovito ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue18360] Won't install. Keeps telling me DLL is missing.

2013-07-10 Thread Terry J. Reedy
Changes by Terry J. Reedy : -- resolution: -> works for me status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing

[issue17535] IDLE: Add an option to show line numbers along the left side of the editor window, and have it enabled by default.

2013-07-10 Thread R. Jayakrishnan
Changes by R. Jayakrishnan : -- nosy: +JayKrish ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue18365] Idle: mock Text class and test thereof

2013-07-10 Thread R. Jayakrishnan
Changes by R. Jayakrishnan : -- nosy: +JayKrish ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue10984] argparse add_mutually_exclusive_group should accept existing arguments to register conflicts

2013-07-10 Thread paul j3
paul j3 added the comment: One usage option is to make a subclass of HelpFormatter (the accepted way of customizing a formatter), and write a function that formats each group independently. For the example case, the resulting format might be: usage: PROG [-h] [-b] [-a | -c] [-a | -d] -h a

[issue18426] Crash when extension does not use PyModule_Create()

2013-07-10 Thread Ivan Johansen
New submission from Ivan Johansen: In Python/importdl.c around line 99 in the function _PyImport_LoadDynamicModule() you can find the code: def = PyModule_GetDef(m); def->m_base.m_init = p; If the module m, which is returned from a newly imported extension, is not created by PyModule_Creat