[issue12713] argparse: allow abbreviation of sub commands by users
Christian Ziemski cz...@gmx.de added the comment: Just for my understanding: Even the current development/testing version: Python 3.2.2 rc 1 (August 14, 2011) isn't new enough here? So I'll have to find out how to install Python 3.3 in parallel to my 2.7.1 (on Fedora 15). Starting with hg clone http://hg.python.org/cpython; now. Until later (after reading http://docs.python.org/devguide/ by myself of course ;-) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12713 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12326] Linux 3: code should avoid using sys.platform == 'linux2'
Georg Brandl ge...@python.org added the comment: Where's the Doc changes? sys.platform is currently clearly documented as being linux2 or linux3. Adding an entry to Misc/NEWS is not enough. -- status: closed - open ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12326 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12792] Document the type field of the tracker in the devguide
Georg Brandl ge...@python.org added the comment: You mean pluralize I guess. -- nosy: +georg.brandl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12792 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12326] Linux 3: code should avoid using sys.platform == 'linux2'
Changes by Georg Brandl ge...@python.org: -- priority: normal - release blocker ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12326 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12803] SSLContext.load_cert_chain() should accept a password argument
New submission from Adam Simpkins a...@adamsimpkins.net: The SSLContext.load_cert_chain() method should accept a password argument to use if the private key is encrypted. Currently it always uses OpenSSL's default password callback, which prompts the user interactively for a password. I've attached a patch that adds an extra password argument, which can be either a string, bytes, bytearray, or a function to call to get the password. -- components: Library (Lib) files: ssl-password.patch keywords: patch messages: 142595 nosy: simpkins priority: normal severity: normal status: open title: SSLContext.load_cert_chain() should accept a password argument type: feature request versions: Python 3.1, Python 3.2 Added file: http://bugs.python.org/file22971/ssl-password.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12803 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12803] SSLContext.load_cert_chain() should accept a password argument
Changes by Ezio Melotti ezio.melo...@gmail.com: -- nosy: +giampaolo.rodola, janssen, pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12803 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12803] SSLContext.load_cert_chain() should accept a password argument
Changes by Antoine Pitrou pit...@free.fr: -- stage: - patch review versions: +Python 3.3 -Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12803 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9878] Avoid parsing pyconfig.h and Makefile by autogenerating extension module
Éric Araujo mer...@netwok.org added the comment: I wouldn’t call this a performance issue. From #4359, you can see that the two main reasons are first to avoid breakage on platforms that put pyconfig.h and Makefile in another package than the interpreter, and most importantly than the code is hard to maintain. Resource usage diminution will just be a nice side-effect. -- type: performance - versions: +Python 3.3 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9878 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12792] Document the type field of the tracker in the devguide
Éric Araujo mer...@netwok.org added the comment: I did! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12792 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12713] argparse: allow abbreviation of sub commands by users
Éric Araujo mer...@netwok.org added the comment: Even the current development/testing version: Python 3.2.2 rc 1 (August 14, 2011) isn't new enough here? No. (Where does the quote come from?) The current development version is 3.3; its version number is currently 3.3.0a0, to mean it was not released yet. 3.2 is a stable release now; 3.2.2c1 is the candidate release of the next bugfix version of 3.2, which is one of the stable versions (with 2.7). So I'll have to find out how to install Python 3.3 in parallel to my 2.7.1 Starting with hg clone http://hg.python.org/cpython; now. Yep, there’s no need to install. Cloning http://hg.python.org/cpython#default will get you 3.3. If you already have a clone for 3.2, you can also pull the default branch in your existing clone; feel free to ask for anything that’s not in the devguide or not clear. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12713 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12713] argparse: allow abbreviation of sub commands by users
Christian Ziemski cz...@gmx.de added the comment: Even the current development/testing version: Python 3.2.2 rc 1 (August 14, 2011) isn't new enough here? No. (Where does the quote come from?) http://python.org/download/releases/ Cloning http://hg.python.org/cpython#default will get you 3.3 I have 3.3 compiled and running now. :-) feel free to ask for anything that’s not in the devguide or not clear. Thanks for the offer! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12713 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12713] argparse: allow abbreviation of sub commands by users
Éric Araujo mer...@netwok.org added the comment: http://python.org/download/releases/ Ah, I understand: the release candidate for 3.2.2 is a testing release, but not a development one :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12713 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12703] Improve error reporting for packaging.util.resolve_name
Éric Araujo mer...@netwok.org added the comment: I’m confused about what the proposed change would actually do. Could you explain what behavior you want to change and how? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12703 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12703] Improve error reporting for packaging.util.resolve_name
Rémy HUBSCHER remy.hubsc...@ionyse.com added the comment: It is exactly what explained Alexis. The __import__ can failed in two case : - The module doesn't exist - There is a error in the module With the previous behaviour, even if the module exist, the message was that it doesn't exists. And it was then not fast forward to guess where was the error. With this new behaviour, if there is an __import__ error and the module file actually exists, then we raise the real exception problem from the module that we try to import. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12703 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12461] it's not clear how the shutil.copystat() should work on symlinks
Hynek Schlawack h...@ox.cx added the comment: This is a sub-issue of #12715. ATM the consent is to add just one symlinks parameter and use the l* functions iff src _and_ dst are symlinks. -- nosy: +hynek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12461 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9993] shutil.move fails on symlink source
Hynek Schlawack h...@ox.cx added the comment: I work on the superficially related #12715 (symlinks for shutil). As we try to mimic the POSIX tools and `mv` indeed doesn't follow links, I agree with the approach of this patch. -- nosy: +hynek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9993 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12326] Linux 3: code should avoid using sys.platform == 'linux2'
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset bf89ff3d1ec9 by Victor Stinner in branch 'default': Issue #12326: update sys.platform doc for Linux http://hg.python.org/cpython/rev/bf89ff3d1ec9 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12326 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12461] it's not clear how the shutil.copystat() should work on symlinks
Éric Araujo mer...@netwok.org added the comment: This report is older but the other one has more discussion and patches, so I’m closing this one. You’re welcome to follow the other. If you think the documentation for current versions should mention how symlinks are handled, please open a new documentation bug. -- nosy: +eric.araujo resolution: - duplicate stage: - committed/rejected status: open - closed superseder: - Add symlink support to shutil functions type: behavior - ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12461 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12783] test_posix failure on FreeBSD 6.4: test_get_and_set_scheduler_and_param
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset a04e70d7d76c by Charles-François Natali in branch 'default': Issue #12783: Fix test_posix failures on FreeBSD buildbots, due to http://hg.python.org/cpython/rev/a04e70d7d76c -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12783 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12715] Add symlink support to shutil functions
Hynek Schlawack h...@ox.cx added the comment: We have an edge case when the caller calls copymode with symlinks=True on an OS that doesn't have lchmod (ie any other than FreeBSD). Should it be a nop (as in copystat), use chmod or raise an Exception? I Personally (and some people on #python-dev) believe it should raise an Exception as the caller made the effort to say that (s)he wants the link _not_ to be followed and it's just one operation (contrary to copystat that does several things). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12715 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4489] shutil.rmtree is vulnerable to a symlink attack
Éric Araujo mer...@netwok.org added the comment: I made two comments on rietveld but the email was rejected. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4489 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Changes by Paul Moore p.f.mo...@gmail.com: -- nosy: +pmoore ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9993] shutil.move fails on symlink source
Éric Araujo mer...@netwok.org added the comment: Can you update the documentation? -- nosy: +eric.araujo versions: +Python 3.3 -Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9993 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4489] shutil.rmtree is vulnerable to a symlink attack
Changes by Hynek Schlawack h...@ox.cx: -- nosy: +hynek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4489 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue4489] shutil.rmtree is vulnerable to a symlink attack
Changes by Petri Lehtinen pe...@digip.org: -- nosy: +petri.lehtinen ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4489 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12803] SSLContext.load_cert_chain() should accept a password argument
Éric Araujo mer...@netwok.org added the comment: I've attached a patch that adds an extra password argument, which can be either a string, bytes, bytearray, or a function to call to get the password. It seems a bit strange to me to accept string types or callable in the same argument. If it just supported strings, people could still write password=somefunction(), right? -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12803 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10504] Trivial mingw compile fixes
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo versions: +Python 3.3 -Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10504 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12780] Clean up tests for pyc/pyo in __file__
Éric Araujo mer...@netwok.org added the comment: Barry, could you review the second part of the patch? (the first was committed) -- nosy: +barry versions: +Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12780 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12781] Mention SO_REUSEADDR near socket doc examples
Éric Araujo mer...@netwok.org added the comment: +1 to Sandro’s patch. Documenting all SO_* constants should be another bug; right now, there is only an index entry for “SO_*”, I suppose for the benefit of C programmers wanting to know where the constants are defined. I think the reason for not documenting all constants is that people should look them up in a C/kernel reference manual. -- nosy: +eric.araujo, georg.brandl ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12781 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12326] Linux 3: code should avoid using sys.platform == 'linux2'
Larry Hastings la...@hastings.org added the comment: So what about doing the same for FreeBSD, SunOS, and Windows? The conversation about this point sort of trailed off. But, dammit, a foolish consistency is the hobgoblin of my small mind. If we're changing linux2 / linux3 to just linux, we should be consistent and do it for everybody. I propose sys.platform under 3.3 should contain things like linux, freebsd, openbsd, darwin, and windows. I further propose we add a sys.platform_major_version which would contain the OS major version number (as an integer!). That'd be 3 for Linux 3.0, 8 for FreeBSD 8, 32 for Win32, and so on. That'd let users easily reconstitute the old value of sys.platform. (Except on Windows. But I am strangely averse to setting sys.platform to win on Windows.) Of course, we should determine this value at runtime rather than build time on platforms where the number could change at runtime. (A counter-example: it need not be late-binding for windows 32 vs 64.) With that addition, we can now address plat-freebsdx.: * Move the all existing plat-freebsdx/IN.py to plat-freebsd/INx.py * Write a new plat-freebsd/IN.py that uses sys.platform_version to read in the correct INx.py. * Alter plat-freebsd/regen to generate INx.py I suspect plat-freebsdx should have used the run-time OS major version all along, so this would be an improvement! And since FreeBSD is the only OS with more than one plat-* entry, the plat-* problem is solved. I'm happy to open a new issue discussing this if that's the right thing to do. -- nosy: +larry ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12326 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12326] Linux 3: code should avoid using sys.platform == 'linux2'
Éric Araujo mer...@netwok.org added the comment: Larry: the scope of this bug was narrowed to the linux breakage only; see #12795 for other platforms. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12326 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12790] doctest.testmod does not run tests in functools.partial functions
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12790 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12793] allow filters in os.walk
Éric Araujo mer...@netwok.org added the comment: Thanks for the report. 2.7 is a stable version, so this would have to go in 3.3. Even where, breaking the function signature wouldn’t be possible, so we would have to add arguments without removing any. Have you looked at shutil.rmtree’s ignore argument and the shutil.ignore_patterns factory function? Maybe that would be a good pattern to copy. -- nosy: +eric.araujo versions: +Python 3.3 -Python 2.7 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12793 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12798] Update mimetypes documentation
Éric Araujo mer...@netwok.org added the comment: Some changes I would like to do +1 on those. -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12798 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11362] image/webp missing from mimetypes.py
Éric Araujo mer...@netwok.org added the comment: On a related note, the Google-originated video codec WebM is used out there and supported by various software. -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11362 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1298813] sysmodule.c: realpath() is unsafe
Changes by Éric Araujo mer...@netwok.org: -- versions: -Python 2.6, Python 3.1 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1298813 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12797] io.FileIO and io.open should support openat
Changes by Éric Araujo mer...@netwok.org: -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12797 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12801] C realpath not used by os.path.realpath
Éric Araujo mer...@netwok.org added the comment: + Return a string representing the canonicalized pathname of *path*. This sounds a bit strange to me; “Return a string representing the canonical version of *path*”. Would it be a good idea to use the full docstring of posixpath.realpath to os.realpath and then just do “realpath = os.realpath” in posixpath? -- nosy: +eric.araujo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12801 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12776] argparse: type conversion function should be called only once
Éric Araujo mer...@netwok.org added the comment: Thanks for the patch. I commented on the code review site, you should have received an email. -- nosy: +eric.araujo versions: +Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12776 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12804] make test should not enable the urlfetch resource
New submission from Éric Araujo mer...@netwok.org: When I run make test on 3.3 now, I get failures because the tests try to make HTTP requests. -- messages: 142621 nosy: eric.araujo, nadeem.vawda priority: normal severity: normal status: open title: make test should not enable the urlfetch resource versions: Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12804 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12804] make test should not enable the urlfetch resource
Nadeem Vawda nadeem.va...@gmail.com added the comment: Are the failures because the machine you're running the test on doesn't have internet access? Or are there problems with some of the tests? The attached patch should solve the problem. -- keywords: +patch Added file: http://bugs.python.org/file22972/i12804.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12804 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12804] make test should not enable the urlfetch resource
Éric Araujo mer...@netwok.org added the comment: Yes, the machine did not have Internet access. Before the run_tests.py patch, the urlfetch resource was not enabled by default. I don’t want to disconnect to test the patch, but it looks good: /home/wok/python/3.3/python -W default -bb -E -m test -r -w -j 0 -u all,-largefile,-urlfetch,-audio,-gui Thanks! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12804 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12804] make test should not enable the urlfetch resource
Éric Araujo mer...@netwok.org added the comment: Before the run_tests.py patch, the urlfetch resource was not enabled by default. I’m referring to the addition of run_tests.py, not this patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12804 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12804] make test should not enable the urlfetch resource
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 228fd2bd83a5 by Nadeem Vawda in branch 'default': Issue #12804: Prevent make test from using network resources. http://hg.python.org/cpython/rev/228fd2bd83a5 -- nosy: +python-dev ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12804 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12804] make test should not enable the urlfetch resource
Changes by Nadeem Vawda nadeem.va...@gmail.com: -- resolution: - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12804 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11651] Improve test targets in Makefile
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 6c4fa9559b7e by Nadeem Vawda in branch 'default': Update README section on testing following issue #11651. http://hg.python.org/cpython/rev/6c4fa9559b7e -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11651 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11657] multiprocessing_{send,recv}fd fail with fds 256
Charles-François Natali neolo...@free.fr added the comment: I looked at multiprocessing code, but didn't understand how to trigger a call to these functions. Makes it hard to come up with a unit test... Here's a sample test: import _multiprocessing import os import socket for i in range(4, 256): os.dup2(1, i) s, r = socket.socketpair() pid = os.fork() if pid == 0: # child fd = _multiprocessing.recvfd(r.fileno()) f = os.fdopen(fd) print(f.read()) f.close() else: # parent f = open('/etc/fstab') _multiprocessing.sendfd(s.fileno(), f.fileno()) f.close() os.waitpid(pid, 0) What happens is that the parent process opens /etc/fstab, and sends the FD to the child process, which prints it. Now, if I run it with the current code, here's what I get: cf@neobox:~/cpython$ ./python ~/test.py Traceback (most recent call last): File /home/cf/test.py, line 18, in module _multiprocessing.sendfd(s.fileno(), f.fileno()) OSError: [Errno 9] Bad file descriptor cf@neobox:~/cpython$ strace -e sendmsg ./python ~/test.py sendmsg(3, {msg_name(0)=NULL, msg_iov(1)=[{\10, 1}], msg_controllen=16, {cmsg_len=16, cmsg_level=SOL_SOCKET, cmsg_type=SCM_RIGHTS, {171137285}}, msg_flags=0}, 0) = -1 EBADF (Bad file descriptor) Traceback (most recent call last): File /home/cf/test.py, line 18, in module _multiprocessing.sendfd(s.fileno(), f.fileno()) OSError: [Errno 9] Bad file descriptor Duh, it's failing with EBADF. Why? cmsg-cmsg_len = CMSG_LEN(sizeof(int)); msg.msg_controllen = cmsg-cmsg_len; *CMSG_DATA(cmsg) = fd; Since we only set one byte in CMSG_DATA, if the other bytes are non-zero, the value stored in CMSG_DATA(cmsg) ends up referring to a non existing FD, hence the EBDAF. With this simple patch: diff -r e49dcb95241f Modules/_multiprocessing/multiprocessing.c --- a/Modules/_multiprocessing/multiprocessing.cSun Aug 21 12:54:06 2011 +0200 +++ b/Modules/_multiprocessing/multiprocessing.cSun Aug 21 16:56:01 2011 +0200 @@ -111,7 +111,7 @@ cmsg-cmsg_type = SCM_RIGHTS; cmsg-cmsg_len = CMSG_LEN(sizeof(int)); msg.msg_controllen = cmsg-cmsg_len; -*CMSG_DATA(cmsg) = fd; +*(int *)CMSG_DATA(cmsg) = fd; Py_BEGIN_ALLOW_THREADS res = sendmsg(conn, msg, 0); @@ -154,7 +154,7 @@ if (res 0) return PyErr_SetFromErrno(PyExc_OSError); -fd = *CMSG_DATA(cmsg); +fd = *(int *)CMSG_DATA(cmsg); return Py_BuildValue(i, fd); } It works fine. Note that if you want to check that for FD 255, you'd have to add something like this at the top: for i in range(4, 256): os.dup2(1, i) Note that I just used a cast to (int *) instead of memcpy() because CMSG_DATA is actually int-aligned, so there's no risk of unaligned-access, and also it's what's commonly used in the litterature. So, would you like to add a test along those lines to test_multiprocessing? AFAICT, multiprocessing.connection is not even documented, but this shows that it really needs some testing... -- nosy: +neologix ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11657 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12326] Linux 3: code should avoid using sys.platform == 'linux2'
Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com added the comment: In case of plat-* directories, please see issue #12619, which proposes some changes. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12326 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Éric Araujo mer...@netwok.org added the comment: Looks like the patch is not enough: http://www.python.org/dev/buildbot/all/builders/x86%20XP-5%203.2/builds/477/steps/test/logs/stdio/text Please see #12785 for a patch to packaging.database that should fix test_packaging failures and needs testing on Windows. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12713] argparse: allow abbreviation of sub commands by users
Christian Ziemski cz...@gmx.de added the comment: Attached a patch against Python 3.3 All the existing tests are still running successfully. But I wasn't able to add additional tests for the new functionality. Writing proper tests is a bit over my head for now - still learning. -- Added file: http://bugs.python.org/file22973/abbrev_subcmds_3.3.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12713 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12782] Multiple context expressions do not support parentheses for continuation across lines
R. David Murray rdmur...@bitdance.com added the comment: Following on to Georg's comment about expressions, as a workaround, note that: with ( open('abc')) as foo: works. -- nosy: +r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12782 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Éric Araujo mer...@netwok.org added the comment: I have to log off for today; another committer can use the attached patch so that we get more info. -- Added file: http://bugs.python.org/file22974/tmp-debug.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12713] argparse: allow abbreviation of sub commands by users
Éric Araujo mer...@netwok.org added the comment: test_argparse has a proper test infrastructure so that people don’t have to write the same boilerplate and assertion code over and over again. If you want, you can probably learn by copy-pasting things. What you want to test is basically that shortened forms work and conflicting abbreviations report an error. -- stage: - test needed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12713 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Roumen Petrov bugtr...@roumenpetrov.info added the comment: diff --git a/Lib/distutils/tests/test_sdist.py b/Lib/distutils/tests/test_sdist.py index 440af98..520289c 100644 --- a/Lib/distutils/tests/test_sdist.py +++ b/Lib/distutils/tests/test_sdist.py @@ -381,6 +381,15 @@ class SDistTestCase(PyPIRCCommandTestCase): self.assertEqual(manifest, ['README.manual']) +if os.name == 'nt': +archive_name = join(self.tmp_dir, 'dist', 'fake-1.0.zip') +with zipfile.ZipFile(archive_name, r, ) as zipfp: +archive = zipfp.infolist() +filenames = [zipinfo.filename for zipinfo in archive] +self.assertEqual(sorted(filenames), ['fake-1.0/PKG-INFO', + 'fake-1.0/README.manual']) +return + archive_name = join(self.tmp_dir, 'dist', 'fake-1.0.tar.gz') archive = tarfile.open(archive_name) try: -- nosy: +rpetrov ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12326] Linux 3: code should avoid using sys.platform == 'linux2'
Martin v. Löwis mar...@v.loewis.de added the comment: So what about doing the same for FreeBSD, SunOS, and Windows? I agree that's definitely out of scope of this issue. If we're changing linux2 / linux3 to just linux, we should be consistent and do it for everybody. I propose sys.platform under 3.3 should contain things like linux, freebsd, openbsd, darwin, and windows. Definitely not. The reasoning that applies to Linux doesn't necessarily apply to the other systems. My understanding that it definitely does not apply to HP-UX, where major version number changes really indicate major changes (unlike in Linux). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12326 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Éric Araujo mer...@netwok.org added the comment: Roumen: I thought too about checking the zipfile on Windows, but with Jeremy’s patch the test force tar.gz generation, so it should amount to the same with less code. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12803] SSLContext.load_cert_chain() should accept a password argument
Adam Simpkins a...@adamsimpkins.net added the comment: It seems a bit strange to me to accept string types or callable in the same argument. If it just supported strings, people could still write password=somefunction(), right? The function is only called if the private key is encrypted and a password is necessary. This allows the code to only prompt for a password if it is actually needed. This also parallels the OpenSSL C API, which only accepts a function to get the password. I added support for plain strings as a convenience. The string argument will be ignored if the file is not encrypted. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12803 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12792] Document the type field of the tracker in the devguide
Terry J. Reedy tjre...@udel.edu added the comment: 'Behaviors' is quite legal. However, behavior Wrong or unexpected behaviors/results/exceptions. ... could well be behavior Wrong or unexpected behavior, result, or exception. ... -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12792 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12721] Chaotic use of helper functions in test_shutil for reading and writing files
Hynek Schlawack h...@ox.cx added the comment: While writing my tests I realized, it would be really useful to make write_file() return the path it wrote to. I need the concatenated filenames most of the time, so I'm getting blocks of: fn = os.path.join(x,y) write_file(fn, 'contents') I'd prefer: fn = write_file((x,y), 'contents') Any thoughts? IMHO a write_file that concats path but doesn't return it is only useful in the tree-functions. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12721 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12803] SSLContext.load_cert_chain() should accept a password argument
Adam Simpkins a...@adamsimpkins.net added the comment: Here's a new patch that accepts any callable. The old patch only accepted actual function objects. -- Added file: http://bugs.python.org/file22975/ssl-password.2.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12803 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Nadeem Vawda nadeem.va...@gmail.com added the comment: Looks like the patch is not enough: http://www.python.org/dev/buildbot/all/builders/x86%20XP-5%203.2/builds/477/steps/test/logs/stdio/text That's a 3.2 builder. You only committed Jeremy's fix to default. I've tested the fix on 3.2 on my own XP system, and it seems to fix the sdist failure. test_install.InstallTestCase.test_record_extensions still fails, though. -- nosy: +nadeem.vawda ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12785] list_distinfo_file is wrong
Nadeem Vawda nadeem.va...@gmail.com added the comment: With the patch applied, I still get failures in test_old_record_extensions and test_record_basic, so it doesn't seem to work. -- nosy: +nadeem.vawda ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12785 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11657] multiprocessing_{send,recv}fd fail with fds 256
Jesse Noller jnol...@gmail.com added the comment: Yes, Charles - the test is not only welcome, but needed - it just can't rely on reading /etc/fstab ;) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11657 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11657] multiprocessing_{send,recv}fd fail with fds 256
Jesse Noller jnol...@gmail.com added the comment: Charles; you have +commit, it seems. I would welcome the patch and test (just as long as the aforementioned reliance on /etc/fstab was removed). -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11657 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset c8e73a89150e by Nadeem Vawda in branch '3.2': Issue #12678: Fix distutils sdist test on Windows. http://hg.python.org/cpython/rev/c8e73a89150e -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset d40856e424fd by Nadeem Vawda in branch '2.7': Issue #12678: Fix distutils sdist test on Windows. http://hg.python.org/cpython/rev/d40856e424fd -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12783] test_posix failure on FreeBSD 6.4: test_get_and_set_scheduler_and_param
Charles-François Natali neolo...@free.fr added the comment: The test now passes on FreeBSD buildbots. Closing. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12783 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11657] multiprocessing_{send,recv}fd fail with fds 256
Charles-François Natali neolo...@free.fr added the comment: Charles; you have +commit, it seems. Yeah, I could of course do this myself, but since Petri already submitted a patch and seemed to be willing to update it with a test, I thought he might be interested in this (I've also seen he's participating to core-mentorship, so this would be a opportunity to help fixing a bug). As for the reliance on /etc/fstab, it was of course just a standalone example to demonstrate how one could test this corner-case ;-) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11657 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12678] test_packaging and test_distutils failures under Windows
Nadeem Vawda nadeem.va...@gmail.com added the comment: The sdist failure is now fixed on the 3.2 XP builders. test_record_extensions still needs attention, though. I also tried backporting Jeremy's fix to 2.7, but that doesn't seem to have worked; the sdist tests is still failing there. Someone who actually knows what they're doing should probably have a look at it at some point. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12678 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6560] socket sendmsg(), recvmsg() methods
Changes by Brian May br...@microcomaustralia.com.au: -- nosy: +ncoghlan ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6560 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12788] test_email fails with -R
Changes by R. David Murray rdmur...@bitdance.com: -- assignee: - r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12788 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12805] Optimzations for bytes.join() et. al
New submission from John O'Connor tehj...@gmail.com: I noticed there are a few more common cases that can be sped up in bytes.join(). When: - The sequence length and separator length are both 0 - The separator length is 0 or 1 - The separator string contains only 1 distinct byte These could also be applied to other sequence types. for i in {{0..5}}; do ./python -m timeit -s f=open('/usr/share/dict/words', 'rb'); L=f.readlines() \ b' '.join(L); done - BEFORE - 100 loops, best of 3: 3.79 msec per loop 100 loops, best of 3: 3.5 msec per loop 100 loops, best of 3: 3.75 msec per loop - AFTER - 100 loops, best of 3: 2.81 msec per loop 100 loops, best of 3: 2.81 msec per loop 100 loops, best of 3: 3.03 msec per loop ~20% speedup Same test on a smaller list (lines from LICENSE file) yields a similar 15-20% speedup. Same test on L = [b'1', b'2', b'3'] yields 10% speedup -- components: Interpreter Core files: bytes_join_optimization.patch keywords: patch messages: 142650 nosy: benjamin.peterson, ezio.melotti, haypo, jcon, pitrou priority: normal severity: normal status: open title: Optimzations for bytes.join() et. al type: performance versions: Python 3.3 Added file: http://bugs.python.org/file22976/bytes_join_optimization.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12805 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12806] argparse: Hybrid help text formatter
New submission from Graylin Kim graylin@gmail.com: When using argparse I frequently run into situations where my helper text is a mix of prose and bullets or options. I need the RawTextFormatter for the bullets, and I need the default formatter for the prose (so the line wraps intelligently). The current HelpFormatter classes are marked as public by name only, so sub-classing them with overrides to get the desired functionality isn't great unless it gets pushed upstream. To that end, I've attached a subclass implementation that I've been using for the following effect: Example: parser = argparse.ArgumentParser(formatter_class=FlexiFormatter) parser.add_argument('--example', help='''\ ... This argument's help text will have this first long line\ ... wrapped to fit the target window size so that your text\ ... remains flexible. ... ... 1. This option list ... 2. is still persisted ... 3. and the option strings get wrapped like this with an\ ...indent for readability. ... ... You must use backslashes at the end of lines to indicate that\ ... you want the text to wrap instead of preserving the newline. ... ... As with docstrings, the leading space to the text block is\ ... ignored. ... ''') parser.parse_args(['-h']) usage: argparse_formatter.py [-h] [--example EXAMPLE] optional arguments: -h, --help show this help message and exit --example EXAMPLE This argument's help text will have this first long line wrapped to fit the target window size so that your text remains flexible. 1. This option list 2. is still persisted 3. and the option strings get wrapped like this with an indent for readability. You must use backslashes at the end of lines to indicate that you want the text to wrap instead of preserving the newline. As with docstrings, the leading space to the text block is ignored. 1. This option list 2. is still persisted 3. and the option strings get wrapped like this with an indent for readability. You must use backslashes at the end of lines to indicate that you want the text to wrap instead of preserving the newline. As with docstrings, the leading space to the text block is ignored. If there is interest in this sort of thing I'd be happy to fix it up for inclusion. -- components: Library (Lib) files: argparse_formatter.py messages: 142651 nosy: GraylinKim priority: normal severity: normal status: open title: argparse: Hybrid help text formatter versions: Python 2.7 Added file: http://bugs.python.org/file22977/argparse_formatter.py ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12806 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12806] argparse: Hybrid help text formatter
Graylin Kim graylin@gmail.com added the comment: I just noticed that the example output above repeats with a different indent. The attached formatter isn't broken, I just messed up the editing on my post. The repeated text isn't part of the output (and shouldn't be there). While I'm certainly at fault here, a feature to preview your post before final submission would likely help people like me to catch these sorts of errors before spamming the world with them. :) Apologies for the double post. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12806 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12805] Optimizations for bytes.join() et. al
Changes by John O'Connor tehj...@gmail.com: -- title: Optimzations for bytes.join() et. al - Optimizations for bytes.join() et. al ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12805 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12776] argparse: type conversion function should be called only once
Arnaud Fontaine ar...@debian.org added the comment: Thanks for the review. Sorry to send that here instead of the review page, but I get an error when replying: Invalid XSRF token.. This looks good, especially if all existing tests still pass as you report, but I wonder about one thing: you have removed the part where the conversion function was applied to the default value, so I expected you to edit the other line were the conversion function was already called, but that’s not the case. Am I misunderstanding something? Yes, sorry, I should have perhaps explained it in further details... Here are some examples: * Example test case 1: parser = argparse.ArgumentParser() parser.add_argument('--foo', type=type_foo_func, default='foo') parser.parse_args('--foo bar'.split()) = Before the patch, type function is called in parse_known_args() for the default given in add_argument(), and then in _parse_known_args() for '--foo bar' given in parse_args above, whereas type function should have been called only for the second one. * Example test case 2: parser = argparse.ArgumentParser() parser.add_argument('--foo', type=type_foo_func) parser.parse_args('--foo bar'.split()) = This was already working well before my patch. * Example test case 3: parser = argparse.ArgumentParser() parser.add_argument('--foo', type=type_foo_func, default='foo') parser.parse_args('') = type_foo_func is called after parsing arguments (none in this case) in my patch. Therefore, my patch just moves the function type call after parsing the arguments (given to parse_args()) instead of before, only and only if it was not previously given in parse_args(). http://bugs.python.org/review/12776/diff/3181/9898#newcode1985 Lib/argparse.py:1985: if hasattr(namespace, action.dest) and \ It is recommended to use parens to group multi-line statements, backslashes are error-prone. I have just updated the patch on the bug report. Thanks. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12776 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12776] argparse: type conversion function should be called only once
Changes by Arnaud Fontaine ar...@debian.org: Removed file: http://bugs.python.org/file22927/py2.7-argparse-call-type-function-once.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12776 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12776] argparse: type conversion function should be called only once
Changes by Arnaud Fontaine ar...@debian.org: Removed file: http://bugs.python.org/file22928/py3k-argparse-call-type-function-once.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12776 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12776] argparse: type conversion function should be called only once
Changes by Arnaud Fontaine ar...@debian.org: Added file: http://bugs.python.org/file22978/py2.7-argparse-call-type-function-once.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12776 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12776] argparse: type conversion function should be called only once
Changes by Arnaud Fontaine ar...@debian.org: Added file: http://bugs.python.org/file22979/py3k-argparse-call-type-function-once.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12776 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10951] gcc 4.6 warnings
Martin Pool m...@sourcefrog.net added the comment: this fixes the pickle warnings, and cleans up some (I'm pretty sure) dead code in there. the pickle tests all pass. -- keywords: +patch nosy: +poolie Added file: http://bugs.python.org/file22980/20110822-1150-python-warnings.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10951 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue9893] Usefulness of the Misc/Vim/ files?
Graeme Cross gjcr...@gmail.com added the comment: Here is a first pass at the README.vim file. Suggestions welcome from VIM power-users! -- nosy: +gjcross Added file: http://bugs.python.org/file22981/README.vim ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9893 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6560] socket sendmsg(), recvmsg() methods
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset c64216addd7f by Nick Coghlan in branch 'default': Add support for the send/recvmsg API to the socket module. Patch by David Watson and Heiko Wundram. (Closes #6560) http://hg.python.org/cpython/rev/c64216addd7f -- nosy: +python-dev resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6560 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11561] coverage of Python regrtest cannot see initial import of libs
Nick Coghlan ncogh...@gmail.com added the comment: Added Ned to the nosy list. For Python core, we should also keep in mind that we do have the option of adding a -X coverage option to avoid the need for the encodings module hack. -- nosy: +nedbat ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11561 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12782] Multiple context expressions do not support parentheses for continuation across lines
Nick Coghlan ncogh...@gmail.com added the comment: As Georg noted, only individual expressions get parentheses based continuations automatically. For statement level use of comma separation, it's decided on a case-by-cases basis as to whether we think it is a legitimate usage based on our style guidelines. That's why 'from location import (name1, name2)' is allowed, but 'import (name1, name2)' is not: we explicitly advise against importing too many modules in a single import statement, but importing multiple names from a single location is often a useful thing to do. However, while the multiple context expression use case is reasonable, there may be a grammar ambiguity problem in this case, since (unlike from-import) with statements allow arbitrary subexpressions. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12782 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11561] coverage of Python regrtest cannot see initial import of libs
Ned Batchelder n...@nedbatchelder.com added the comment: The tip of the coverage.py repo (https://bitbucket.org/ned/coveragepy) has a new implementation of the encodings hack which seems to work well. Of course, an option to run a module before anything else in the interpreter would make the whole thing much simpler. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11561 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12715] Add symlink support to shutil functions
Changes by Марк Коренберг socketp...@gmail.com: -- nosy: +mmarkk ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12715 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12807] Optimizations for {bytearray,bytes,unicode}.strip()
New submission from John O'Connor tehj...@gmail.com: bytearray() is using a less efficient implementation of split() than its similar friends bytes and unicode. I added a couple extra checks to return early in {bytes,unicode} split(). - if length is 0 - if left strip removed all bytes Looking at just how similar these 3 implementations are I feel that we could also unify/generalize them into one generic helper implementation and leave the object marshaling up to the type specific methods. -- components: Interpreter Core files: strip_perf.patch keywords: patch messages: 142660 nosy: benjamin.peterson, ezio.melotti, haypo, jcon, pitrou priority: normal severity: normal status: open title: Optimizations for {bytearray,bytes,unicode}.strip() type: performance versions: Python 3.3 Added file: http://bugs.python.org/file22982/strip_perf.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12807 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12808] Coverage of codecs.py
New submission from Tennessee Leeuwenburg tleeuwenb...@gmail.com: Increases the coverage of codecs.py by about 3 lines... -- files: mywork.patch keywords: patch messages: 142661 nosy: ncoghlan, tleeuwenburg priority: normal severity: normal status: open title: Coverage of codecs.py versions: Python 3.4 Added file: http://bugs.python.org/file22983/mywork.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12808 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12808] Coverage of codecs.py
Tennessee Leeuwenburg tleeuwenb...@gmail.com added the comment: Also some pep8 compliance outside of the scope of the added lines of code. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12808 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12809] Missing new setsockopts in Linux (eg: IP_TRANSPARENT)
New submission from Michael Farrell micolous...@gmail.com: Recently, iptables has added support for transparent proxies using a new TPROXY target on Linux2. This requires a new option in setsockopts, IP_TRANSPARENT. There's some background on the feature here: http://www.mjmwired.net/kernel/Documentation/networking/tproxy.txt I've created a patch to the header regen scripts on Linux2 that should expose this functionality to Python. They'll need to be run to generate the headers again. I notice that `_socket` doesn't include the names of socket options from this location, instead using a local database. I had trouble trying to get `linux/in.h` included in that file, so I included a work-around which defines it statically for now. It needs some work but it causes a lot of breakage when I try to do this -- and I don't know enough about the Linux sockets API to fix this properly. -- components: Library (Lib) files: extra_linux_sockopts.diff keywords: patch messages: 142663 nosy: micolous priority: normal severity: normal status: open title: Missing new setsockopts in Linux (eg: IP_TRANSPARENT) type: feature request versions: Python 3.3 Added file: http://bugs.python.org/file22984/extra_linux_sockopts.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12809 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1298813] sysmodule.c: realpath() is unsafe
Mihai Ibanescu mihai.ibane...@gmail.com added the comment: It's a real shame the original patch was not applied before py3k was branched, the code is now different. Antoine, my autoconf knowledge is limited, I don't know how you'd test for realpath accepting a NULL argument (and doing the right thing) at compile time. My involvement with this bug is fairly limited at this point, I would like to see it fixed, but having seen no movement on it for almost 6 years now, maybe it's not as critical as I thought it was. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1298813 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue10951] gcc 4.6 warnings
Martin Pool m...@sourcefrog.net added the comment: This fixes every compiler warning so that Python build with -Werror on Ubuntu Oneiric alpha (gcc 4.6.1-7ubuntu1). * PyMem_Resize is a macro that mutates its first argument; the return value shouldn't be used. * Some variables in sre are (apparently harmlessly) not used when validating the opcodes. * gethostbyname_r return codes weren't used and should be; it is not guaranteed to set h_errno correctly (though it does seem to do so here) * a few vairables in pthread and tkappintr are not used in some preprocessor productions. * setup.py should detect linux kernel 3.0 as linux, and therefore able to build ossaudiodev I don't get all the errors mentioned by haypo. At least some seem already fixed. -- Added file: http://bugs.python.org/file22985/20110822-1352-gcc-warnings.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10951 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue11159] Sax parser crashes if given unicode file name
John Chandler therealmetal...@gmail.com added the comment: Confirmed about not being an issue in Python 3. Just checked with Python 3.3.0a0 and the example works fine - no exception raised. -- nosy: +John.Chandler ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11159 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6484] No unit test for mailcap module
Changes by Anthony Briggs anthony.bri...@gmail.com: -- nosy: +anthonyb, ncoghlan versions: +Python 3.3 -Python 3.2 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6484 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue6484] No unit test for mailcap module
Anthony Briggs anthony.bri...@gmail.com added the comment: Added ncoghlan to the nosy list - we're reviewing/fixing unit test coverage as part of the sprints at PyconAU. Thanks Gnofi! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6484 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12768] docstrings for the threading module
Graeme Cross gjcr...@gmail.com added the comment: Threading module docstrings added for all classes and public methods; mainly used a summarised version of information from the documentation. -- keywords: +patch nosy: +gjcross Added file: http://bugs.python.org/file22986/threading_docstrings.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12768 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12767] document threading.Condition.notify
Graeme Cross gjcr...@gmail.com added the comment: I have added documentation for the 'n' parameter of threading.Condition.notify as part of the overhaul of the threading module's docstrings. Reference: #12768 -- nosy: +gjcross ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12767 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue1215] Python hang when catching a segfault
Martin Pool m...@sourcefrog.net added the comment: The documentation for this can now point to the faulthandler module (in Python 3). -- nosy: +poolie ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1215 ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com
[issue12768] docstrings for the threading module
Eli Bendersky eli...@gmail.com added the comment: On Mon, Aug 22, 2011 at 07:39, Graeme Cross rep...@bugs.python.org wrote: Graeme Cross gjcr...@gmail.com added the comment: Threading module docstrings added for all classes and public methods; mainly used a summarised version of information from the documentation. Thanks for the patch, Graeme. I will try to find time to review and apply it in a few days, if no one else will do it until then. Eli -- Added file: http://bugs.python.org/file22987/unnamed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12768 ___div dir=ltrdiv class=gmail_quoteOn Mon, Aug 22, 2011 at 07:39, Graeme Cross span dir=ltrlt;a href=mailto:rep...@bugs.python.org;rep...@bugs.python.org/agt;/span wrote:brblockquote class=gmail_quote style=margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex; br Graeme Cross lt;a href=mailto:gjcr...@gmail.com;gjcr...@gmail.com/agt; added the comment:br br Threading module docstrings added for all classes and public methods; mainly used a summarised version of information from the documentation.br/blockquote/divbrbrThanks for the patch, Graeme.brI will try to find time to review and apply it in a few days, if no one else will do it until then.br brElibr/div ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com