[issue26736] Use HTTPS protocol in links

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If these changes are acceptable, we should change the :rfc:, :pep:, etc roles to produce links with https. I was not sure that these changes are worth, it was just interesting to me to research how many links support the HTTPS protocol now. --

[issue26729] Incorrect __text_signature__ for sorted

2016-04-11 Thread Raymond Hettinger
Raymond Hettinger added the comment: I don't think we should start down the path of changing APIs just to accommodate weakness in the generation of the text signature. We don't want to encourage unreadable oddities like sorted(reverse=False, iterable=source). Best readability comes from the

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Roundup Robot
Roundup Robot added the comment: New changeset b114a0650c44 by Serhiy Storchaka in branch '3.5': Issue #26733: Fixed formatting line numbers in test_dis. https://hg.python.org/cpython/rev/b114a0650c44 New changeset e0816ce68952 by Serhiy Storchaka in branch 'default': Issue #26733: Fixed

[issue26736] Use HTTPS protocol in links

2016-04-11 Thread Georg Brandl
Georg Brandl added the comment: +1 -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If this is new feature, perhaps the docs need the versionchanged directive. Otherwise the patch should be applied to all maintained branches. Added other comments on Rietveld. -- nosy: +serhiy.storchaka ___

[issue25061] Add native enum support for argparse

2016-04-11 Thread paul j3
paul j3 added the comment: desbma: Rereading your latest code and comment: > * The meaning of the 'type' parameter for StoreEnumAction is somewhat > different than for other actions (enum class vs callable that validates) it occurred to me that that parameter does not have to be named

[issue26729] Incorrect __text_signature__ for sorted

2016-04-11 Thread Erik Welch
Erik Welch added the comment: Interesting observation, Martin. Upon further consideration, the call signature for sorted really is quite odd. It doesn't behave like any other builtin function. Currently, "iterable" is positional-only, and "key=" and "reverse=" are keyword only. I would

[issue26699] locale.str docstring is incorrect: "Convert float to integer"

2016-04-11 Thread Luiz Poleto
Changes by Luiz Poleto : -- keywords: +patch Added file: http://bugs.python.org/file42440/issue26699.patch ___ Python tracker ___

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Xiang Zhang
Xiang Zhang added the comment: I update the documentation. Learning from devguide, the change of whatsnew is the committer's work. ;) -- Added file: http://bugs.python.org/file42439/add_staticmethod_and_classmethod_when_dis.dis_a_class_v4.patch ___

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Nick Coghlan
Nick Coghlan added the comment: The code and test changes in the latest patch look good to me. For documentation, I suggest updating https://docs.python.org/3/library/dis.html#dis.dis to: - say "it disassembles all methods (including class and static methods)" when describing how classes are

[issue11205] Evaluation order of dictionary display is different from reference manual.

2016-04-11 Thread Nick Coghlan
Nick Coghlan added the comment: Temporarily reopening this as a docs bug - I think it's worth mentioning in the "Porting to Python 3.5" section of the What's New docs and as a "version changed" note in the dis module docs, as even though it's obscure, anyone that was inadvertently relying on

[issue26737] csv.DictReader throws generic error when fieldnames is accessed for non-text file

2016-04-11 Thread Josh Rosenberg
Josh Rosenberg added the comment: This already behaves usefully in 3.5 where reading fieldnames from a DictReader wrapping a file opened in binary mode gets you: _csv.Error: iterator should return strings, not bytes (did you open the file in text mode?) And 2.7 is highly unlikely to make fit

[issue25061] Add native enum support for argparse

2016-04-11 Thread paul j3
paul j3 added the comment: The best way to get an idea added is to write a good complete patch. 2nd best is to provide constructive input on ideas that are already here. 3rd is to illustrate how you would hope to use such a feature. Include ideas on how the usage/help/error display would

[issue9334] argparse does not accept options taking arguments beginning with dash (regression from optparse)

2016-04-11 Thread Martin Panter
Martin Panter added the comment: My main concern with the patch is that it only half fixes the problem. It sounds like it will allow parsing “--opt -x” (if “-x” is not registered as an option), but will still refuse “--opt -h”, assuming “-h” is registered by default. What is the barrier to

[issue25187] bdist_rpm fails due to wrong hardcoded assumption about RPM filename format

2016-04-11 Thread David Ward
David Ward added the comment: Thanks again for your feedback. I revised this patch as requested to conform to changes also being made in issue 25627. Please review this new patch. I tested this successfully under both Python 3.4.3 and Python 2.7.11 on Fedora 23. Note that "import subprocess"

[issue25627] distutils : file "bdist_rpm.py" does not quote filenames when executing the rpm command

2016-04-11 Thread David Ward
David Ward added the comment: This revised patch has a small change so that the subprocess output is decoded from a byte sequence to a string, which is necessary when running this under Python 3. With this change, this worked for me on Fedora 23 with Python 3.4.3. It also worked on Fedora 23

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread Bar Harel
Bar Harel added the comment: Any idea how to test it then? I found this happening by chance because I care about efficiency too much. We can't just stick timeit in random areas and hope to get results. -- ___ Python tracker

[issue9334] argparse does not accept options taking arguments beginning with dash (regression from optparse)

2016-04-11 Thread Cherniavsky Beni
Cherniavsky Beni added the comment: +1, is there anything missing to apply Paul's patch? Can I additional suggest a change to the error message, e.g.: $ prog --foo -bar prog: error: argument --foo: expected one argument (tip: use --foo=-bar to force interpretation as argument of --foo)

[issue26673] Tkinter error when opening IDLE configuration menu

2016-04-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: #24745 changed the default fixed font from Courier to TkFixedFontin 3.5.0, 3.4.4, and 2.7.11 when using tcl/tk 8.5+. On some OSes, the latter is not Courier and looks much better. I don't know why the two behave differently on some systems. Since this is

[issue23129] sqlite3 COMMIT nested in SELECT returns unexpected results

2016-04-11 Thread Daniel Lenski
Daniel Lenski added the comment: I agree on the nastiness of this bug. It's been plaguing my production code for months and I had been at a loss to explain why I've been getting duplicate rows until I found this SO post:

[issue26739] Errno 10035 a non-blocking socket operation could not be completed immediately

2016-04-11 Thread MICHAEL JACOBSON
Changes by MICHAEL JACOBSON <922...@isd624.org>: -- nosy: -MICHAEL JACOBSON, paul.moore, steve.dower, tim.golden, zach.ware ___ Python tracker ___

[issue26739] idle: Errno 10035 a non-blocking socket operation could not be completed immediately

2016-04-11 Thread STINNER Victor
Changes by STINNER Victor : -- components: +IDLE nosy: +paul.moore, steve.dower, tim.golden, zach.ware title: Errno 10035 a non-blocking socket operation could not be completed immediately -> idle: Errno 10035 a non-blocking socket operation could not be

[issue26739] Errno 10035 a non-blocking socket operation could not be completed immediately

2016-04-11 Thread MICHAEL JACOBSON
New submission from MICHAEL JACOBSON: So far I've got past the "bug in program" stage of debugging, but this came up: IDLE internal error in runcode() Traceback (most recent call last): File "C:\Python27\lib\idlelib\rpc.py", line 235, in asyncqueue self.putmessage((seq, request)) File

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: Another question is how often this situation occurs in practice and whether it's worth spending some bits, CPU cycles and developer time on "fixing" this. -- ___ Python tracker

[issue2943] Distutils should generate a better error message when the SDK is not installed

2016-04-11 Thread Ivan Pozdeev
Ivan Pozdeev added the comment: The vsvarsall.bat message should direct to https://wiki.python.org/moin/WindowsCompilers rather than some 3rd-party site (even more so, one with user-generated content like SO). E.g.: "Unable to find vcvarsall.bat. A required version of MS VC++ compilers is

[issue24951] Idle test_configdialog fails on Fedora 23, 3.6

2016-04-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: This and #26673 are duplicates. The latter also reports failure on Arch Linux and other Python versions. While our default policy is to keep the earliest report open, I am closing this as #26673 has more information, including from Petr. --

[issue26738] listname.strip() does not work right if the name ends with an 'o'

2016-04-11 Thread SilentGhost
SilentGhost added the comment: Documentation [0] has a very clear explanation of how str.strip works. [0] https://docs.python.org/2/library/stdtypes.html#str.strip -- nosy: +SilentGhost resolution: -> not a bug stage: -> resolved status: open -> closed

[issue26738] listname.strip() does not work right if the name ends with an 'o'

2016-04-11 Thread dileep k
Changes by dileep k : -- title: listname.strip does not work right if the name ends with an 'o' -> listname.strip() does not work right if the name ends with an 'o' ___ Python tracker

[issue26738] listname.strip does not work right if the name ends with an 'o'

2016-04-11 Thread dileep k
New submission from dileep k: 12:54:38 | ~ | #1 $ python -V Python 2.7.6 12:54:41 | ~ | #2 $ python Python 2.7.6 (default, Jun 22 2015, 17:58:13) [GCC 4.8.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> 'media.log'.strip('.log') 'media' >>>

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread Antti Haapala
Antti Haapala added the comment: Also what is important to notice is that the behaviour occurs *exactly* because the current heuristics *work*; the allocations were successfully organized so that one arena could be freed as soon as possible. The question is that is it sane to try to free the

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread Antti Haapala
Antti Haapala added the comment: I said that *munmapping* is not the smart thing to do: and it is not, if you're going to *mmap* soon again. -- ___ Python tracker

[issue24745] Better default font for editor

2016-04-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: The change from "Courier" to "TkDefaultFont" causes Options => Configure IDLE to fail at least on Arch Linux (#26673) and Fedora 23 (also #24951). The reason is still obscure to me. I will leave this closed, close #24951 as duplicate, and patch on #26673

[issue26736] Use HTTPS protocol in links

2016-04-11 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___

[issue26737] csv.DictReader throws generic error when fieldnames is accessed for non-text file

2016-04-11 Thread Bayo Opadeyi
Changes by Bayo Opadeyi : -- title: csv.DictReader throws generic error when fieldnames is accessed on non-text file -> csv.DictReader throws generic error when fieldnames is accessed for non-text file ___ Python tracker

[issue26737] csv.DictReader throws generic error when fieldnames is accessed on non-text file

2016-04-11 Thread Bayo Opadeyi
New submission from Bayo Opadeyi: If you use the csv.DictReader to open a non-text file and try to access fieldnames on it, it crashes with a generic error instead of something specific. -- messages: 263199 nosy: boyombo priority: normal severity: normal status: open title:

[issue25910] Fixing links in documentation

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: For XML-RPC extensions we can use a web archive: https://web.archive.org/web/20130120074804/http://ontosys.com/xml-rpc/extensions.php. There are precedences of using it for other dead links. Opened separate issue26736 for https-zation. --

[issue26736] Use HTTPS protocol in links

2016-04-11 Thread Serhiy Storchaka
New submission from Serhiy Storchaka: Proposed patch makes links in the docs to use the HTTPS protocol if possible. All changed links are tested manually. -- assignee: docs@python components: Documentation files: links_https.patch keywords: patch messages: 263197 nosy: alex,

[issue26718] super.__init__ leaks memory if called multiple times

2016-04-11 Thread Guido van Rossum
Guido van Rossum added the comment: Actually, the refcount bug is still a bug. -- resolution: not a bug -> status: closed -> open ___ Python tracker ___

[issue26718] super.__init__ leaks memory if called multiple times

2016-04-11 Thread Brett Cannon
Brett Cannon added the comment: Based on Guido's feedback and the fact that this isn't documented usage of super() and hence no promises to not re-initialize, I'm closing as "not a bug". Sorry, Kevin. -- resolution: -> not a bug status: open -> closed

[issue26693] Exception ignored in: in _shutdown, assert tlock.locked()

2016-04-11 Thread skydoom
skydoom added the comment: Hi Pitrou, would you be able to look at my issue and the proposed pathc? Thanks -- ___ Python tracker ___

[issue14265] Fully qualified test name in failure output

2016-04-11 Thread Aviv Palivoda
Aviv Palivoda added the comment: Included is a patch with the suggested change. I changed the TestCase.__str__ method to: return "%s (%s.%s)" % (self._testMethodName, strclass(self.__class__), self._testMethodName) instead of return "%s (%s)" % (self._testMethodName,

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread Antoine Pitrou
Antoine Pitrou added the comment: > ... and it turns out that munmapping is not always that smart thing to do: I don't think a silly benchmark says anything about the efficiency of our allocation strategy. If you have a real-world use case where this turns up, then please post about it.

[issue26735] os.urandom(2500) fails on Solaris 11.3

2016-04-11 Thread Matthew Ryan
New submission from Matthew Ryan: On Solaris 11.3 (intel tested, but I assume issue is on SPARC as well), I found the following fails: import os os.urandom(2500) The above throws OSError: [Errno 22] Invalid argument. It turns out that the Solaris version of getrandom() is limited to

[issue26734] Repeated mmap\munmap calls during temporary allocation

2016-04-11 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- resolution: -> duplicate status: open -> closed superseder: -> Use new madvise()'s MADV_FREE on the private heap ___ Python tracker

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread Bar Harel
Changes by Bar Harel : -- nosy: +bar.harel ___ Python tracker ___ ___ Python-bugs-list

[issue26734] Repeated mmap\munmap calls during temporary allocation

2016-04-11 Thread STINNER Victor
STINNER Victor added the comment: FYI a discussion started in the issue #26601. -- nosy: +haypo ___ Python tracker ___

[issue26734] Repeated mmap\munmap calls during temporary allocation

2016-04-11 Thread Brett Cannon
Changes by Brett Cannon : -- components: -Benchmarks ___ Python tracker ___ ___

[issue26734] Repeated mmap\munmap calls during temporary allocation

2016-04-11 Thread Brett Cannon
Changes by Brett Cannon : -- nosy: -brett.cannon ___ Python tracker ___ ___

[issue26734] Repeated mmap\munmap calls during temporary allocation

2016-04-11 Thread Bar Harel
New submission from Bar Harel: After asking a question regarding performance in StackOverflow, I received an answer which seemed like a design problem in object allocation. This is the question: http://stackoverflow.com/q/36548518/1658617 Seems like it ignores the garbage allocation settings

[issue25187] bdist_rpm fails due to wrong hardcoded assumption about RPM filename format

2016-04-11 Thread David Ward
David Ward added the comment: Please review this revised patch. Thank you. -- Added file: http://bugs.python.org/file42432/python-bdist_rpm-evaluate-_rpmfilename.patch ___ Python tracker

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Xiang Zhang
Xiang Zhang added the comment: After researching the code, I think changing ' %-4d' to '%3d' in dis_bug708901 is right. Since I added some some lines and the lineno of test_bug708901 has arrived at 100+ and the leading space should not be there. According to the code of dis.dis, the right

[issue25910] Fixing links in documentation

2016-04-11 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +barry, tim.peters ___ Python tracker ___ ___

[issue25910] Fixing links in documentation

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: > Serhiy, the OpenSSL links are now https They works with http. Some links (including python.org) are now redirected from http to https. It may be worth to add https explicitly. -- ___ Python tracker

[issue25910] Fixing links in documentation

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Fixed links to "A Byte of Python" and OpenSSL. Not fixed dead links: http://www.zope.com/ http://www.pythonlabs.com/logos.html (http://www.pythonlabs.com/ exists but is not too useful) http://www.vex.net/parnassus/ (looks as this project is dead)

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread Antti Haapala
Antti Haapala added the comment: > Maybe we need an heuristic to release the free arena after N calls to object > allocator functions which don't need this free arena. That'd be my thought; again I believe that `madvise` could be useful there; now `mmap`/`munmap` I believe is particularly

[issue25910] Fixing links in documentation

2016-04-11 Thread Roundup Robot
Roundup Robot added the comment: New changeset bb10867ffe28 by Serhiy Storchaka in branch '3.5': Issue #25910: Fixed more links in the docs. https://hg.python.org/cpython/rev/bb10867ffe28 New changeset 61c7deea9e6a by Serhiy Storchaka in branch '2.7': Issue #25910: Fixed more links in the docs.

[issue25910] Fixing links in documentation

2016-04-11 Thread SilentGhost
SilentGhost added the comment: Serhiy, the OpenSSL links are now https -- ___ Python tracker ___ ___

[issue26601] Use new madvise()'s MADV_FREE on the private heap

2016-04-11 Thread STINNER Victor
STINNER Victor added the comment: > ... and it turns out that munmapping is not always that smart thing to do: > http://stackoverflow.com/questions/36548518/variable-assignment-faster-than-one-liner py -3 -m timeit "tuple(range(2000)) == tuple(range(2000))" 1 loops, best of 3: 97.7 usec

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

2016-04-11 Thread Barry A. Warsaw
Changes by Barry A. Warsaw : -- status: closed -> open ___ Python tracker ___ ___

[issue25910] Fixing links in documentation

2016-04-11 Thread Martin Panter
Martin Panter added the comment: The bug tracker importer still exists if you know what revision to look it up in: -- ___ Python tracker

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread SilentGhost
Changes by SilentGhost : -- nosy: +ncoghlan, yselivanov stage: -> patch review ___ Python tracker ___

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Xiang Zhang
Xiang Zhang added the comment: Though don't know why but simply replace %-4d with %3d in dis_bug708901 can fix the test. I updated the patch so all the tests pass and then I'll spend some time figuring out why. -- Added file:

[issue25910] Fixing links in documentation

2016-04-11 Thread SilentGhost
SilentGhost added the comment: Licence text shouldn't be touched, I think. http://www.openssl.org/docs/apps/ciphers.html#CIPHER_LIST_FORMAT became https://www.openssl.org/docs/manmaster/apps/ciphers.html#CIPHER-LIST-FORMAT If Martin still have the importer code somewhere, he probably could

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Xiang Zhang
Changes by Xiang Zhang : -- components: +Library (Lib) type: -> behavior versions: +Python 3.6 ___ Python tracker ___

[issue26733] staticmethod and classmethod are ignored when disassemble class

2016-04-11 Thread Xiang Zhang
New submission from Xiang Zhang: Though the documentation tells when disassembling a class, it disassembles all methods for dis.dis, but staticmethod and classmethod are ignored. I don't know whether this is intended. I write to patch to add staticmethod and classmethod. But unfortunately

[issue26673] Tkinter error when opening IDLE configuration menu

2016-04-11 Thread Petr Viktorin
Petr Viktorin added the comment: I can reproduce this with Python 2.7.11 and somewhat recent build from hg default (3.6.0a0) on Fedora 23. Putting these lines in my personal config-main.cfg solves this:: [EditorWindow] font= courier idlelib/config-main.def has a different default::

[issue25910] Fixing links in documentation

2016-04-11 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- resolution: fixed -> stage: resolved -> status: closed -> open ___ Python tracker ___

[issue25910] Fixing links in documentation

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Following dead links left: Doc/library/xmlrpc.client.rst (line 42) brokenhttp://ontosys.com/xml-rpc/extensions.php - Doc/license.rst (line 22) brokenhttp://www.zope.com/ - (line 131) brokenhttp://www.pythonlabs.com/logos.html - HTTP Error

[issue25910] Fixing links in documentation

2016-04-11 Thread Roundup Robot
Roundup Robot added the comment: New changeset ce721df212cf by Serhiy Storchaka in branch '3.5': Issue #25910: Fixed dead links in the docs. https://hg.python.org/cpython/rev/ce721df212cf New changeset 14e00e7e4d51 by Georg Brandl in branch '2.7': Closes #25910: fix dead and permanently

[issue26720] memoryview from BufferedWriter becomes garbage

2016-04-11 Thread Martin Panter
Martin Panter added the comment: To create a memoryview with unlimited lifetime, I understand we need to nominate an “exporting object”, which becomes memoryview.obj. Using a bytes object here might be the simplest fix for just BufferedWriter. However it looks like the buffer is shared with

[issue26732] multiprocessing sentinel resource leak

2016-04-11 Thread SilentGhost
Changes by SilentGhost : -- nosy: +jnoller, sbt ___ Python tracker ___ ___

[issue22659] SyntaxError in the configure_ctypes

2016-04-11 Thread Berker Peksag
Berker Peksag added the comment: Thanks for the report. I think this is a problem in your dev environment (wrong path or something like that). For some reason, you are trying to run Python 3 setup.py in Python 2. -- nosy: +berker.peksag resolution: -> not a bug stage: -> resolved

[issue26585] Use html.escape to replace _quote_html in http.server

2016-04-11 Thread Xiang Zhang
Xiang Zhang added the comment: Happy to see it works. Thanks for your reviews too. :) -- ___ Python tracker ___

[issue26200] SETREF adds unnecessary work in some cases

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is a patch that adds extra usages of the Py_SETREF() macro (in particular in deque implementation). It doesn't fix bugs or improve performance, but makes the code shorter and perhaps makes it more readable. If you think that some of these changes

[issue26200] SETREF adds unnecessary work in some cases

2016-04-11 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Restored safe usage of Py_SETREFs introduced not in issue20440: in issue25928, changeset 3292b4862627, and issue25945. -- ___ Python tracker

[issue26200] SETREF adds unnecessary work in some cases

2016-04-11 Thread Roundup Robot
Roundup Robot added the comment: New changeset aa5dbc32d313 by Serhiy Storchaka in branch '3.5': Issue #26200: Restored more safe usages of Py_SETREF. https://hg.python.org/cpython/rev/aa5dbc32d313 New changeset f21740a1abde by Serhiy Storchaka in branch '2.7': Issue #26200: Restored more safe

[issue25061] Add native enum support for argparse

2016-04-11 Thread leycec
leycec added the comment: I strongly support this feature request. Unsurprisingly, I wholeheartedly agree with desbma's heroic persistence and wholeheartedly disagree with rhettinger's curt dismissal. > IMO, this adds more complexity than it solves. Strongly disagree. Because "argparse"