[issue12619] Automatically regenerate platform-specific modules

2011-10-20 Thread Petri Lehtinen
Changes by Petri Lehtinen : -- nosy: -petri.lehtinen ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://ma

[issue13231] sys.settrace - document 'some other code blocks' for 'call' event type

2011-10-20 Thread anatoly techtonik
New submission from anatoly techtonik : http://docs.python.org/library/sys.html#sys.settrace While writing settrace function you need to know what kind of data is expected and how to get more information about it. Current documentation for sys.settrace doesn't give too much answers. To improve

[issue13230] test_resources fails

2011-10-20 Thread Nadeem Vawda
Nadeem Vawda added the comment: This seems to be a duplicate of issue 13193. -- nosy: +nadeem.vawda resolution: -> duplicate stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker

[issue13193] test_packaging and test_distutils failures under Windows

2011-10-20 Thread Nadeem Vawda
Nadeem Vawda added the comment: Issue 13230 (closed as duplicate) reports another Linux failure in test_resources. Changing the title, since it isn't Windows-specific. -- nosy: +anikom15 stage: -> needs patch ___ Python tracker

[issue13193] test_packaging and test_distutils failures

2011-10-20 Thread Nadeem Vawda
Changes by Nadeem Vawda : -- title: test_packaging and test_distutils failures under Windows -> test_packaging and test_distutils failures ___ Python tracker ___ ___

[issue9168] setuid in smtp.py sheds privileges before binding port

2011-10-20 Thread Petri Lehtinen
Petri Lehtinen added the comment: The patch looks good to me and fixes the problem. To reproduce, try this: sudo python -m smtpd 127.0.0.1:25 It raises a "socket.error: [Errno 13] Permission denied" when trying to bind to the privileged port. Attached a refreshed the patch that applies c

[issue8503] smtpd SMTPServer does not allow domain filtering

2011-10-20 Thread Petri Lehtinen
Changes by Petri Lehtinen : -- nosy: +petri.lehtinen versions: +Python 3.3 -Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mail

[issue3802] smtpd.py __getaddr insufficient handling

2011-10-20 Thread Petri Lehtinen
Petri Lehtinen added the comment: AFAIK, the extra MAIL FROM and RCPT TO parameters are only valid for ESMTP. smtpd doesn't currently handle ESMTP, so this should not be a problem. -- nosy: +petri.lehtinen versions: +Python 2.7, Python 3.2, Python 3.3 -Python 2.6 _

[issue8503] smtpd SMTPServer does not allow domain filtering

2011-10-20 Thread Petri Lehtinen
Petri Lehtinen added the comment: This sounds like an important feature to me. A few points: - I'd rename the function name from accept_domain to e.g. validate_domain for clarity - There could also be a function to validate the loca part of each recipient addresses. Or maybe the function sh

[issue12816] smtpd uses library outside of the standard libraries

2011-10-20 Thread Petri Lehtinen
Changes by Petri Lehtinen : -- nosy: +petri.lehtinen ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue13201] Implement comparison operators for range objects

2011-10-20 Thread Mark Dickinson
Mark Dickinson added the comment: I get a test failure in test_hash (which is checking exactly that the hash(range) uses the default object hash, so that test is clearly out of date now). Apart from that, the latest patch looks good to me. I'm going to give this a couple of days in case anyo

[issue13201] Implement comparison operators for range objects

2011-10-20 Thread STINNER Victor
STINNER Victor added the comment: +one = PyLong_FromLong(1); +if (!one) +return -1; +cmp_result = PyObject_RichCompareBool(r0->length, one, Py_EQ); +Py_DECREF(one); If would be nice to have a PyLong_CompareLong() function. -- nosy: +haypo __

[issue13218] test_ssl failures on Ubuntu 11.10

2011-10-20 Thread Nadeem Vawda
Nadeem Vawda added the comment: > none of the buildbots are having this problem. Actually, it turns out the Ubuntu ARM builder is hitting the same failures. First failure for each branch was on 14 October (the day after 11.10 came out): http://www.python.org/dev/buildbot/all/builders/ARM%2

[issue9574] allow whitespace around central '+' in complex constructor

2011-10-20 Thread Mark Dickinson
Changes by Mark Dickinson : -- stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue13232] Logging: Unicode Error

2011-10-20 Thread Thomas Guettler
New submission from Thomas Guettler : In changeset fe6be0426e0d the format() method was changed. Unfortunately it does not catch all unicode decode errors. I think line 482 of logging/__init__.py should be modified: to this (add 'replace'): s = s + record.exc_text.decode(sys.getfilesystemenco

[issue13232] Logging: Unicode Error

2011-10-20 Thread Vinay Sajip
Vinay Sajip added the comment: Can you tell me what the actual data was which failed to be decoded? Is there more than one encoding in effect (e.g. one for the filesystem, and another for the other data in the exception being logged)? -- nosy: +vinay.sajip ___

[issue12915] Add inspect.locate and inspect.resolve

2011-10-20 Thread Vinay Sajip
Vinay Sajip added the comment: The version in logging.config appears to be doing the same job, but is shorter: def _resolve(name): """Resolve a dotted name to a global object.""" name = name.split('.') used = name.pop(0) found = __import__(used) for n in name: used =

[issue13232] Logging: Unicode Error

2011-10-20 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti stage: -> test needed type: -> behavior ___ Python tracker ___ ___ Python-bugs-list

[issue13232] Logging: Unicode Error

2011-10-20 Thread STINNER Victor
Changes by STINNER Victor : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue12619] Automatically regenerate platform-specific modules

2011-10-20 Thread Jakub Wilk
Jakub Wilk added the comment: * STINNER Victor , 2011-10-19, 22:55: >>FYI, in Debian we have at least: >>one package using the CDROM module, >Is it cdsuite? (http://offog.org/code/cdsuite.html) No, Freevo . >>3 packages using the IN module, >I found policykit (i

[issue13227] Option to make the lru_cache type specific

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset cba503a2c468 by Raymond Hettinger in branch 'default': Issue 13227: Option to make the lru_cache() type specific (suggested by Andrew Koenig). http://hg.python.org/cpython/rev/cba503a2c468 -- nosy: +python-dev

[issue13227] Option to make the lru_cache type specific

2011-10-20 Thread Raymond Hettinger
Raymond Hettinger added the comment: Victor, Ezio, and Nick, thanks for the review. Andrew, thanks for the feature request. -- resolution: -> fixed status: open -> closed ___ Python tracker __

[issue13233] os.acces documentation error

2011-10-20 Thread Guilherme Moro
New submission from Guilherme Moro : http://docs.python.org/library/os.html#os.access points out that I should use try: fp = open("myfile") except IOError as e: if e.errno == errno.EACCESS: return "some default data" # Not a permission error. raise else: with fp:

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-10-20 Thread R. David Murray
R. David Murray added the comment: This patch has caused a non-trivial regression between 3.2 and 3.2.1. The scenario in which I observed it is poplib. I create a POP3 connection with a timeout. At one point in its processing, poplib is reading lines until it gets a line '.\r\n', at which

[issue12529] cgi.parse_header fails on double quotes and semicolons

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset cfc545e028e0 by Senthil Kumaran in branch '3.2': News entry for Issue12529 and Issue12604 http://hg.python.org/cpython/rev/cfc545e028e0 New changeset 52a4e899966c by Senthil Kumaran in branch 'default': News entry for Issue12529 and Issue12604 http

[issue13219] re module doc has minor inaccuracy in character sets

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 07eca800cdb4 by Ezio Melotti in branch '2.7': #13219: clarify section about character sets in the re documentation. http://hg.python.org/cpython/rev/07eca800cdb4 New changeset dc96a89ac192 by Ezio Melotti in branch '3.2': #13219: clarify section ab

[issue12619] Automatically regenerate platform-specific modules

2011-10-20 Thread STINNER Victor
STINNER Victor added the comment: For Freevo: yes, it uses the CDROM module. But this module doesn't look to be perfect because Freevo has a fallback for FreeBSD and another for... Linux (because of missing CDROM.CDROM_DRIVE_STATUS?): - try: from CDROM import *

[issue13219] re module doc has minor inaccuracy in character sets

2011-10-20 Thread Ezio Melotti
Ezio Melotti added the comment: Done, thanks for the report! -- resolution: -> fixed stage: commit review -> committed/rejected status: open -> closed ___ Python tracker ___ __

[issue13233] os.acces documentation error

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 1d8fad82c32d by Ezio Melotti in branch '3.2': #13233: fix typo. http://hg.python.org/cpython/rev/1d8fad82c32d New changeset 99c8b93c57cd by Ezio Melotti in branch 'default': #13233: null merge with 3.2. http://hg.python.org/cpython/rev/99c8b93c57cd

[issue13234] os.listdir breaks with literal paths

2011-10-20 Thread Manuel de la Pena
New submission from Manuel de la Pena : During the development of an application that needed to write paths longer than 260 chars we opted to use \\?\ as per http://msdn.microsoft.com/en-us/library/windows/desktop/aa365247(v=vs.85).aspx#maxpath. When working with literal paths the following th

[issue13233] os.acces documentation error

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8bf9724dcd49 by Ezio Melotti in branch '2.7': #13233: fix typo. http://hg.python.org/cpython/rev/8bf9724dcd49 -- ___ Python tracker __

[issue13233] os.acces documentation error

2011-10-20 Thread Ezio Melotti
Ezio Melotti added the comment: Fixed, thanks for the report! -- assignee: docs@python -> ezio.melotti nosy: +ezio.melotti resolution: -> fixed stage: -> committed/rejected status: open -> closed versions: +Python 3.2, Python 3.3 ___ Python tracker

[issue12753] \N{...} neglects formal aliases and named sequences from Unicode charnames namespace

2011-10-20 Thread Ezio Melotti
Ezio Melotti added the comment: If the latest patch is fine I'll commit it shortly. -- stage: patch review -> commit review ___ Python tracker ___ __

[issue13219] re module doc has minor inaccuracy in character sets

2011-10-20 Thread Florent Xicluna
Florent Xicluna added the comment: Well, the actual behavior is a little bit more complex to describe. >>> re.match('[.-_a-z]', '-') >>> re.match('[._-a-z]', '-') <_sre.SRE_Match object at 0x100418e80> >>> re.match('[.-_a-z]', 'b') <_sre.SRE_Match object at 0x100418b88> >>> re.match('[._-a-z]

[issue12753] \N{...} neglects formal aliases and named sequences from Unicode charnames namespace

2011-10-20 Thread Tom Christiansen
Tom Christiansen added the comment: Yes, it looks good. Thank you very much. -tom -- ___ Python tracker ___ ___ Python-bugs-list ma

[issue13219] re module doc has minor inaccuracy in character sets

2011-10-20 Thread Ezio Melotti
Ezio Melotti added the comment: Indeed. The "tricks" of putting '-' at the beginning/end and ']' at the beginning are well known and works with most of the implementations afaik, but I would consider the behavior of [._-a-z] as an implementation detail and don't expect it to work elsewhere.

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-10-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: > One could then continue processing, sending new transactions to the POP > server and getting responses. That's optimistic. You don't know how much data has been lost in readline(). Sure, again your test server, it happens to work :) But again other kinds o

[issue13234] os.listdir breaks with literal paths

2011-10-20 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +brian.curtin, pitrou, tim.golden stage: -> patch review versions: +Python 3.2, Python 3.3 ___ Python tracker ___ __

[issue13234] os.listdir breaks with literal paths

2011-10-20 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue13235] logging.warn() is not documented

2011-10-20 Thread anatoly techtonik
New submission from anatoly techtonik : No docs for logging.warn() alias. -- assignee: docs@python components: Documentation messages: 146039 nosy: docs@python, techtonik priority: normal severity: normal status: open title: logging.warn() is not documented versions: Python 2.7, Python 3

[issue13235] logging.warn() is not documented

2011-10-20 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +vinay.sajip ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-10-20 Thread R. David Murray
R. David Murray added the comment: I don't think it is optimistic. The poplib transaction pattern is: send a command, get a response. If the response is not properly terminated, throw it away. Send a new command, get a response. There's no ambiguity there. In addition, this is a common t

[issue6397] Implementing Solaris "poll" in the "select" module

2011-10-20 Thread Jesús Cea Avión
Jesús Cea Avión added the comment: I want to move this forward. Apparently, "/dev/poll" could be actually used transparently in python "select.poll()" implementation. The semantics seems to be the same, so we could use the "poll" syscall or "/dev/poll" statically at compiling time, or dinami

[issue6397] Implementing Solaris "poll" in the "select" module

2011-10-20 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- versions: +Python 3.3 -Python 2.7, Python 3.2 ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue13235] logging.warn() is not documented

2011-10-20 Thread Vinay Sajip
Vinay Sajip added the comment: That's deliberate. The original code (before incorporation into Python) had warn(), which was kept for backward compatibility. The docs refer to warning() because that's what everyone is supposed to use. The method names map to the lower case of the appropriate

[issue13236] unittest needs more flush calls

2011-10-20 Thread Peter Eisentraut
New submission from Peter Eisentraut : I'm using the TextTestRunner class in unittest/runner.py with a special file-like object passed in as stream. Doing this loses some output, because the run() method (and some lower-level methods) don't always call flush() on the stream. There is also no

[issue13236] unittest needs more flush calls

2011-10-20 Thread R. David Murray
R. David Murray added the comment: How can a lack of flushes lose output? Delay it maybe, but unless your file class is broken I don't see how data would be lost. -- nosy: +r.david.murray versions: -Python 2.6 ___ Python tracker

[issue13235] logging.warn() is not documented

2011-10-20 Thread anatoly techtonik
anatoly techtonik added the comment: I've got a traceback, because forgot to implement this method in logging wrapper. It should be either deprecated and removed or documented. -- status: closed -> open ___ Python tracker

[issue13226] Expose RTLD_* constants in the posix module

2011-10-20 Thread STINNER Victor
STINNER Victor added the comment: Updated patch: remove "either" in the documentation. Thanks neologix par the review. -- Added file: http://bugs.python.org/file23483/posix_rtld-2.patch ___ Python tracker ___

[issue12753] \N{...} neglects formal aliases and named sequences from Unicode charnames namespace

2011-10-20 Thread Florent Xicluna
Changes by Florent Xicluna : -- nosy: +flox ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-10-20 Thread Florent Xicluna
Changes by Florent Xicluna : -- nosy: +flox ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.o

[issue13235] logging.warn() is not documented

2011-10-20 Thread Vinay Sajip
Vinay Sajip added the comment: It is deprecated by not being documented. It certainly isn't going to have documentation added for it. Which code was calling the warn() method? Is it not possible to change this to call warning()? - Original Message - > From: anatoly techtonik > To: v

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-10-20 Thread Gregory P. Smith
Gregory P. Smith added the comment: If the server failed to close a transaction the protocol stream is over unless you mime relying on hope and luck. Poplib has a nasty set of server implementation bugs to work around here. Readline as defined today no longer suits its needs but I still strongl

[issue7322] Socket timeout can cause file-like readline() method to lose data

2011-10-20 Thread R. David Murray
R. David Murray added the comment: Your suggestion sounds good to me. I still think that it is a common failure mode in a client server transaction for the server to fail to send a (complete) line that the client is expecting, and vice versa, requiring a timeout, but not necessarily a "restar

[issue13125] test_all_project_files() expected failure

2011-10-20 Thread Mikhail Novikov
Mikhail Novikov added the comment: Updated patch to work properly with verbosity. -- Added file: http://bugs.python.org/file23484/i13125-2.patch ___ Python tracker ___ _

[issue13236] unittest needs more flush calls

2011-10-20 Thread Ezio Melotti
Ezio Melotti added the comment: Can you provide a minimal test case to reproduce the issue? -- nosy: +ezio.melotti stage: -> test needed versions: -Python 3.1 ___ Python tracker _

[issue9168] setuid in smtp.py sheds privileges before binding port

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 7d92b94b0eec by Florent Xicluna in branch '3.2': Issue #9168: now smtpd is able to bind privileged port. http://hg.python.org/cpython/rev/7d92b94b0eec New changeset bbd92b42508e by Florent Xicluna in branch 'default': Issue #9168: now smtpd is able

[issue9168] setuid in smtp.py sheds privileges before binding port

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset d2f303861c98 by Florent Xicluna in branch '2.7': Issue #9168: now smtpd is able to bind privileged port. http://hg.python.org/cpython/rev/d2f303861c98 -- ___ Python tracker

[issue9168] setuid in smtp.py sheds privileges before binding port

2011-10-20 Thread Florent Xicluna
Florent Xicluna added the comment: Fixed. Thank you for the patch. -- nosy: +flox resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker __

[issue12170] index() and count() methods of bytes and bytearray should accept byte ints

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset c1effa2cdd20 by Antoine Pitrou in branch 'default': Issue #12170: The count(), find(), rfind(), index() and rindex() methods http://hg.python.org/cpython/rev/c1effa2cdd20 -- nosy: +python-dev ___ Python

[issue12170] index() and count() methods of bytes and bytearray should accept byte ints

2011-10-20 Thread Antoine Pitrou
Antoine Pitrou added the comment: Patch committed, thank you! -- assignee: rhettinger -> resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker _

[issue13235] logging.warn() is not documented

2011-10-20 Thread anatoly techtonik
anatoly techtonik added the comment: ./trac/env.py:self.log.warn('base_url option not set in configuration, ' ./trac/env.py:self.log.warn('Couldn\'t write sample configuration file (%s)', e, ./trac/web/main.py:##env.log.warn("%d uncollectable objects

[issue13235] logging.warn() is not documented

2011-10-20 Thread Ezio Melotti
Ezio Melotti added the comment: I think it's better to avoid "deprecations by missing documentation" and document explicitly if something is deprecated. What happens is that people working on some old code find the deprecated method, check the doc to see what it does, don't find anything, get

[issue13237] subprocess docs should use emphasise convenience functions

2011-10-20 Thread Nick Coghlan
New submission from Nick Coghlan : Many typical subprocess use cases can now be handled simply via the convenience functions: subprocess.call() subprocess.check_call() subprocess.check_output() However, readers of the documentation could be forgiven for not realising that, since the doc

[issue13237] subprocess docs should use emphasise convenience functions

2011-10-20 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue13214] Cmd: list available completions from the cmd.Cmd subclass and filter out EOF handler(s)

2011-10-20 Thread Garrett Cooper
Garrett Cooper added the comment: Here's a version incorporating your suggestion and better documenting the choices and the method for overriding purposes. I have a few reservations with the current implementation: 1. As noted, the information for the class really could be and should be cache

[issue13238] Add shell command helpers to shutil module

2011-10-20 Thread Nick Coghlan
New submission from Nick Coghlan : I've been doing a few systems administration tasks with Python recently, and shell command invocation directly via the subprocess module is annoyingly clunky (even with the new convenience APIs). Since subprocess needs to avoid the shell by default for securi

[issue13238] Add shell command helpers to shutil module

2011-10-20 Thread Alex Gaynor
Alex Gaynor added the comment: These feel like a shell injection waiting to happen to me. -- nosy: +alex ___ Python tracker ___ ___ P

[issue13237] subprocess docs should emphasise convenience functions

2011-10-20 Thread Nick Coghlan
Changes by Nick Coghlan : -- title: subprocess docs should use emphasise convenience functions -> subprocess docs should emphasise convenience functions ___ Python tracker ___ _

[issue13235] logging.warn() is not documented

2011-10-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset 37479f0f68bc by Vinay Sajip in branch 'default': Closes #13235: Added deprecation for warn() methods and function in logging. http://hg.python.org/cpython/rev/37479f0f68bc -- nosy: +python-dev resolution: -> fixed stage: needs patch -> com

[issue13232] Logging: Unicode Error

2011-10-20 Thread Thomas Guettler
Changes by Thomas Guettler : Added file: http://bugs.python.org/file23486/unicodedecodeerror-in-logging.py ___ Python tracker ___ ___ Python-b

[issue13238] Add shell command helpers to shutil module

2011-10-20 Thread Nick Coghlan
Nick Coghlan added the comment: And that's exactly the problem - a web developer's or security auditor's "shell injection" is a system administrator's "this language sucks". These wrappers are the kind of thing you want for shell invocations when using Python as a replacement for a shell scri

[issue13232] Logging: Unicode Error

2011-10-20 Thread Thomas Guettler
Thomas Guettler added the comment: I attached a testcase (unicodedecodeerror-in-logging.py). If the filesystemencoding is UTF-8 and the source code is encoded in latin1, then the logging fails. It happens because there is a German umlaut in the comment behind 1/0. I added 'replace' to the de

[issue13238] Add shell command helpers to shutil module

2011-10-20 Thread Nick Coghlan
Nick Coghlan added the comment: Perhaps a better idea would be to use different names, so it's clearer at the point of invocation that the shell is being invoked (and hence shell injection attacks are a potential concern). For example: shell_call check_shell_call check_shell_output Tha