[issue14234] CVE-2012-0876 (hash table collisions CPU usage DoS) for embedded copy of expat

2012-03-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 04ff6e206b98 by Gregory P. Smith in branch '2.7': Fixes Issue #14234: CVE-2012-0876: Randomize hashes of xml attributes http://hg.python.org/cpython/rev/04ff6e206b98 New changeset ada6bfbeceb8 by Gregory P. Smith in branch '2.7': Fixes Issue 14234:

[issue14200] Idle shell crash on printing non-BMP unicode character

2012-03-15 Thread Roger Serwy
Roger Serwy added the comment: I stand corrected. Thank you for the information. The behavior of the console depends on its locale. IDLE has no facility for changing the locale of the PyShell window. Should this option be included somewhere? -- __

[issue14114] 2.7.3rc1 chm gives JS error

2012-03-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 11a11e5cac0f by Ezio Melotti in branch '2.7': #14114: don't include copybutton.js in the htmlhelp output. http://hg.python.org/cpython/rev/11a11e5cac0f New changeset 36ec90b6b5e5 by Ezio Melotti in branch '2.7': #14114: don't include copybutton.js

[issue14127] add st_*time_ns fileds to os.stat(), add ns keyword to os.*utime*(), os.*utimens*() expects a number of nanoseconds

2012-03-15 Thread Guido van Rossum
Guido van Rossum added the comment: Somehow patch #2 doesn't show up in Rietveld. :-( Anyway, I'll leave completion of the review to Antoine, who's more competent in this area. :-) -- ___ Python tracker

[issue14324] Do not rely on AC_RUN_IFELSE tests in the configury

2012-03-15 Thread Matthias Klose
New submission from Matthias Klose : AC_RUN_IFELSE tests can't be used in cross builds, and have to fall back to some default in the case of a cross build. This is a meta issue to collect changes for the conversion of such tests. -- assignee: doko components: Cross-Build keywords: pat

[issue14323] Normalize math precision in RGB/YIQ conversion

2012-03-15 Thread Brian Landers
Changes by Brian Landers : Added file: http://bugs.python.org/file24867/acks.patch ___ Python tracker ___ ___ Python-bugs-list mailing list Un

[issue14323] Normalize math precision in RGB/YIQ conversion

2012-03-15 Thread Brian Landers
New submission from Brian Landers : There doesn't seem to be a standard definition for the constants to use when doing the matrix calculations to convert RGB to YIQ or vise versa. Also, the current colorsys library uses two digits of precision for RGB-YIQ but six digits for YIQ-RGB. The att

[issue13694] asynchronous connect in asyncore.dispatcher does not set addr

2012-03-15 Thread Matt Joiner
Matt Joiner added the comment: I should mention that this failure to set addr is unusual seeing as most socket instances are wrapping AF_INET* domain sockets, and aren't likely to connect without blocking. This is quite likely a reason nobody has observed it until now. It *is* desirable to s

[issue14294] Requirements are not properly copied into metatdata of dist-info

2012-03-15 Thread Preston Holmes
Preston Holmes added the comment: fixed in http://hg.python.org/distutils2/rev/f453054a7d8b I worked on this fix with Tarek at the pycon sprints - still a bit unfamiliar with this tracker and how to best cross ref revs with ticket numbers This ticket can't be closed until the question of the

[issue14322] More test coverage for hmac.py

2012-03-15 Thread Brian Landers
New submission from Brian Landers : Adding some tests to non-default code paths in hmac.py to get to 100% coverage. -- components: Tests files: test_hmac.patch keywords: patch messages: 155913 nosy: packetslave priority: normal severity: normal status: open title: More test coverage for

[issue14321] Do not run pgen during the build if files are up to date

2012-03-15 Thread Matthias Klose
Changes by Matthias Klose : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://ma

[issue14321] Do not run pgen during the build if files are up to date

2012-03-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 52597f888e7a by Matthias Klose in branch 'default': - Issue #14321: Do not run pgen during the build if files are up to date. http://hg.python.org/cpython/rev/52597f888e7a -- nosy: +python-dev ___ Python

[issue13872] socket.detach doesn't mark socket._closed

2012-03-15 Thread Matt Joiner
Matt Joiner added the comment: Yes it should. A cursory glance shows that __repr__ returns incorrect if _closed is not marked, and an unnecessary mop-up call to socket.close is avoided. -- nosy: +giampaolo.rodola, haypo, stutzbach ___ Python tracke

[issue14321] Do not run pgen during the build if files are up to date

2012-03-15 Thread Matthias Klose
New submission from Matthias Klose : For a cross build, make tries to run pgen built for the host machine, not the build machine. However it is not necessary to run pgen at all if all the files are up to date. This change implements it. The release script (if something like this exists) should

[issue14320] set.add can return boolean indicate newly added item

2012-03-15 Thread Raymond Hettinger
Changes by Raymond Hettinger : -- assignee: -> rhettinger nosy: +rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue14320] set.add can return boolean indicate newly added item

2012-03-15 Thread Matt Joiner
Changes by Matt Joiner : Added file: http://bugs.python.org/file24863/bench_set_add.py ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue14320] set.add can return boolean indicate newly added item

2012-03-15 Thread Matt Joiner
New submission from Matt Joiner : set.add can return True to indicate a newly added item to the set, or False if the item was already present. The C function PySet_Add returns -1 on error, and 0 on success currently. This is extended to return 1 if the item is newly added, and 0 if it was alre

[issue14275] pysetup create doesn't handle install requirements

2012-03-15 Thread Alexis Metaireau
Alexis Metaireau added the comment: Thanks for reporting this, Jan-Jaap, I've marked this issue as easy, it's mostly a matter of looking at the passed parameter and outputing the list in the generated file, respecting the PEP 345 format (http://www.python.org/dev/peps/pep-0345/#requires-dist

[issue14275] pysetup create doesn't handle install requirements

2012-03-15 Thread Alexis Metaireau
Changes by Alexis Metaireau : -- dependencies: -Requirements are not properly copied into metatdata of dist-info ___ Python tracker ___ _

[issue3871] cross and native build of python for mingw32 with packaging

2012-03-15 Thread Matthias Klose
Changes by Matthias Klose : -- components: +Cross-Build -Build, Distutils2 ___ Python tracker ___ ___ Python-bugs-list mailing list Uns

[issue14275] pysetup create doesn't handle install requirements

2012-03-15 Thread Alexis Metaireau
Changes by Alexis Metaireau : -- dependencies: +Requirements are not properly copied into metatdata of dist-info ___ Python tracker ___ __

[issue14318] clarify "may not" in time.steady docs

2012-03-15 Thread Jim Jewett
New submission from Jim Jewett : http://docs.python.org/dev/library/time.html#time.steady Current: """Return the current time as a floating point number expressed in seconds. This clock advances at a steady rate relative to real time and it may not be adjusted. The reference point of the retur

[issue14280] packaging.pypi should not require checksums

2012-03-15 Thread Alexis Metaireau
Alexis Metaireau added the comment: If no MD5 checksum is present on the crawled simple index, then we don't have to check them. This means we introduce a potential security hole here (md5 checksums were added for a reason). What could be done is to explicitely don't check them if asked so. F

[issue14279] packaging.pypi should support flat directories of distributions

2012-03-15 Thread Alexis Metaireau
Alexis Metaireau added the comment: It is supposed to work already, but I'm not sure this is tested or complete. I'll have a closer look on this. +1 on the general idea. -- assignee: eric.araujo -> alexis ___ Python tracker

[issue12684] profile does not dump stats on exception like cProfile does

2012-03-15 Thread Matt Joiner
Matt Joiner added the comment: Jim the code was lifted verbatim from Lib/cProfile.py, line 47. That code in cProfile.py has not changed since 2006 when it was committed by Armin Rigo. I can modernize it if it's a requirement to get it committed, but I'm also okay with my conservative patch a

[issue14319] cleanup index switching mechanism on packaging.pypi

2012-03-15 Thread Alexis Metaireau
New submission from Alexis Metaireau : I need to do some general cleanup on packaging/d2, and especially on this bit. Currently, the implementation is way too complicated for what it does. -- assignee: alexis components: Distutils2 messages: 155903 nosy: alexis, tarek priority: normal s

[issue5302] Allow package_data specs/globs to match directories

2012-03-15 Thread Alexis Metaireau
Alexis Metaireau added the comment: Agreed on this one. That would avoid to have a new syntax for this case, which seems to be very common. -- ___ Python tracker ___ ___

[issue14294] Requirements are not properly copied into metatdata of dist-info

2012-03-15 Thread Alexis Metaireau
Alexis Metaireau added the comment: Thanks for reporting this Preston, Could you be a bit more precise on this one? What is the input you are giving (in the dist-info) and what is not being done? (what's the expected output and what's what you have as a result of running util.egginfo_to_dist

[issue11880] add a {dist-info} category to distutils2

2012-03-15 Thread Alexis Metaireau
Alexis Metaireau added the comment: Hey, is there any news on this bug? Berker? -- ___ Python tracker ___ ___ Python-bugs-list mailin

[issue14317] index.simple module lacking in distutils2

2012-03-15 Thread Alexis Metaireau
Alexis Metaireau added the comment: The APIs of distutils2 have changed. the "index" module is now named "pypi". So, doing something like:: >>> from distutils2.pypi.simple import Crawler should work. -- ___ Python tracker

[issue14200] Idle shell crash on printing non-BMP unicode character

2012-03-15 Thread Martin v . Löwis
Martin v. Löwis added the comment: > On Windows Vista, I do see that print() behaves differently than > evaluating the expression. An exception is raised for: > print('\N{GOTHIC LETTER AHSA}') As is for most other characters not supported in your OEM code page, e.g. (likely) '\N{GREEK SMALL LET

[issue14317] index.simple module lacking in distutils2

2012-03-15 Thread Alexis Metaireau
Changes by Alexis Metaireau : -- resolution: -> wont fix status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue829370] math.signum(int)

2012-03-15 Thread Frank Breitling
Frank Breitling added the comment: Unfortunately my reply to the list lost all quotes, so I try to answer again through the web interface: --- > I'm not quite sure why that formula would be "elegant" in the first place, Because its short. > and I most certainly don't understand why 0.5*sign(

[issue829370] math.signum(int)

2012-03-15 Thread Frank Breitling
Frank Breitling added the comment: Because its short. Because the former is a proper mathematical expression, while the latter is python jargon with limited use elsewhere. Exactly, why is there no correct implementation of Julian date in python time or datetime? For most practical purposes I

[issue14318] clarify http://docs.python.org/dev/library/time.html#time.steady

2012-03-15 Thread Jim Jewett
Changes by Jim Jewett : -- assignee: docs@python components: Documentation nosy: Jim.Jewett, docs@python priority: normal severity: normal status: open title: clarify http://docs.python.org/dev/library/time.html#time.steady type: enhancement versions: Python 3.3

[issue2377] Replace __import__ w/ importlib.__import__

2012-03-15 Thread Brett Cannon
Brett Cannon added the comment: Yes, that's the important bit. Thomas has given it a once over at this point so you should be able to see his review comments as well to prevent duplicate work. -- ___ Python tracker

[issue14230] Delegating generator is not always visible to debugging tools such as inspect & pdb

2012-03-15 Thread Benjamin Peterson
Benjamin Peterson added the comment: I would appreciate the patch could be regenerated against the latest default. -- ___ Python tracker ___

[issue14317] index.simple module lacking in distutils2

2012-03-15 Thread Pierre Lecointre
Changes by Pierre Lecointre : -- title: index.simple module licking in distutils2 -> index.simple module lacking in distutils2 versions: +Python 2.6 ___ Python tracker ___ _

[issue14317] index.simple module licking in distutils2

2012-03-15 Thread Pierre Lecointre
New submission from Pierre Lecointre : Got an error, in debian squeeze (python 2.6) and Ubuntu 11.10 (python 2.7) : plec@cezoffsrv04:~$ python Python 2.6.6 (r266:84292, Dec 27 2010, 00:02:40) [GCC 4.4.5] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> from di

[issue14255] tempfile.gettempdir() didn't return the path with correct case.

2012-03-15 Thread 勇刚 罗
勇刚 罗 added the comment: It's possible to getting actual file name under Windows. http://stackoverflow.com/questions/74451/getting-actual-file-name-with-proper-casing-on-windows -- ___ Python tracker __

[issue829370] math.signum(int)

2012-03-15 Thread Merlijn van Deen
Merlijn van Deen added the comment: Although there is one use case which I now realise due to your post: easier 1-on-1 implementation of existing algorithms. Another possible reason to implement it is that it's not that hard to implement the sign() function wrongly, if it also has to work wit

[issue829370] math.signum(int)

2012-03-15 Thread Merlijn van Deen
Merlijn van Deen added the comment: I'm not quite sure why that formula would be "elegant" in the first place, and I most certainly don't understand why 0.5*sign((100*YY)+MM-190002.5) + 0.5 is more elegant than ((100*YY)+MM > 190002.5) or (((YY = 1900) and (MM > 2.5)) or (YY > 1900)) or r

[issue14316] Broken link in grammar.rst

2012-03-15 Thread Berker Peksag
Changes by Berker Peksag : -- title: Broken link in grammar.html -> Broken link in grammar.rst ___ Python tracker ___ ___ Python-bugs-

[issue14308] '_DummyThread' object has no attribute '_Thread__block'

2012-03-15 Thread sbt
sbt added the comment: Ignore my last message... -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue14308] '_DummyThread' object has no attribute '_Thread__block'

2012-03-15 Thread sbt
sbt added the comment: _DummyThread.__init__() explicitly deletes self._Thread__block: def __init__(self): Thread.__init__(self, name=_newname("Dummy-%d")) # Thread.__block consumes an OS-level locking primitive, which # can never be used by a _DummyThread. Since a

[issue14316] Broken link in grammar.html

2012-03-15 Thread Berker Peksag
New submission from Berker Peksag : In the rationale section: http://docs.python.org/devguide/grammar.html#rationale This link is not working: http://docs.python.org/devguide/HowtoChangePython%27sGrammar -- components: Devguide messages: 155888 nosy: berker.peksag, ezio.melotti priorit

[issue14308] '_DummyThread' object has no attribute '_Thread__block'

2012-03-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: > However, on checking my logs again this morning, I have a few hundred > more of the same error, so that was not effective. Did you restart your server? In your patch, you could use the traceback module (e.g. http://docs.python.org/dev/library/traceback.html

[issue829370] math.signum(int)

2012-03-15 Thread Frank
Frank added the comment: Here an example where the signum function provides an elegant way to calculate the Julian date: def julian_date(YY,MM,DD,HR,Min,Sec,UTcor): return 367*YY - (7*(YY+((MM+9)/12))/4) + (275*MM/9)+ DD + 1721013.5 + UTcor/24 - 0.5*sign((100*YY)+MM-190002.5) + 0.5 + HR/

[issue14308] '_DummyThread' object has no attribute '_Thread__block'

2012-03-15 Thread Dustin Kirkland
Dustin Kirkland added the comment: /usr/lib/python2.7/threading.pyc is stock from my distribution, Ubuntu 12.04 LTS, which has python-2.7.3~rc1-1ubuntu2. I did manually apply the patch I've attached here to /usr/lib/python2.7/threading.py, and it *seemed* to silence those errors. However, on

[issue11085] expose _abcoll as collections.abc

2012-03-15 Thread Laurent Mazuel
Changes by Laurent Mazuel : -- nosy: +Laurent.Mazuel ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue11826] Leak in atexitmodule

2012-03-15 Thread Stefan Krah
Stefan Krah added the comment: Antoine Pitrou wrote: > Well, if it doesn't crash, it's probably ok ;) > Perhaps check modstate->atexit_callbacks for non-NULL? > Or do we trust free() to do the right thing? I was initially surprised by this, but the docs state that it's safe: http://docs.pytho

[issue14308] '_DummyThread' object has no attribute '_Thread__block'

2012-03-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: I don't understand how that can happen, since _Thread__block is initialized in Thread.__init__, which is called by _DummyThread.__init__. Did you somehow monkeypatch the threading module? -- nosy: +pitrou ___ Pytho

[issue11959] smtpd cannot be used without affecting global state

2012-03-15 Thread Vinay Sajip
Vinay Sajip added the comment: > I notice that your logging test code doesn't override create_socket. Is that > no longer needed? I removed that code from test_logging, but the code in the BitBucket repo shows how I'd like smtpd to be changed. I would of course prefer to avoid copying stuff

[issue14310] Socket duplication for windows

2012-03-15 Thread sbt
sbt added the comment: It appears that the 4th argument of the socket constructor is undocumented, so presumably one is expected to use fromfd() instead. Maybe you could have a frominfo(info) function (to match fromfd(fd,...)) and a dupinfo(pid) method. (It appears that multiprocessing uses

[issue1641] asyncore delayed calls feature

2012-03-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 59f0e6de54b3 by Giampaolo Rodola' in branch 'default': (sched) when run() is invoked with blocking=False return the deadline of the next scheduled call in the scheduler; this use case was suggested in http://bugs.python.org/issue1641#msg149453 htt

[issue14314] logging smtp handler (and test) timeout issue

2012-03-15 Thread Vinay Sajip
Vinay Sajip added the comment: I've added changes to the test code and a timeout to SMTPHandler (docs still to be updated), and I'll let it run on the buildbots for a bit before looking at timeouts for 3.2/2.7. Marking as pending to remind me. -- assignee: -> vinay.sajip resolution:

[issue14314] logging smtp handler (and test) timeout issue

2012-03-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4b3f81720809 by Vinay Sajip in branch 'default': Fixes #14314: Improved SMTP timeout handling. http://hg.python.org/cpython/rev/4b3f81720809 -- nosy: +python-dev ___ Python tracker

[issue14307] Make subclassing SocketServer simpler for non-blocking frameworks

2012-03-15 Thread Antoine Pitrou
Antoine Pitrou added the comment: As discussed on python-dev, I'm against this change. Furthermore, removing the explicit select() call also removes the opportunity to use a wake-up fd instead of the current polling mechanism. -- nosy: +pitrou ___

[issue14308] '_DummyThread' object has no attribute '_Thread__block'

2012-03-15 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: test needed -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe

[issue14255] tempfile.gettempdir() didn't return the path with correct case.

2012-03-15 Thread Jeff McNeil
Jeff McNeil added the comment: Here's a tiny patch that just changes normcase->normpath. This fixes the casing issue at the 'gettempdir' level, though it doesn't address the 'normcase' function itself. Note that *both* macpath.py and ntpath.py use .lower, which obviously won't fly on case-s

[issue14315] zipfile.ZipFile() unable to open zip File

2012-03-15 Thread pleed
New submission from pleed : zipfile.ZipFile("bla.apk") crashes, but should not since other tools work perfectly with this file. Python 2.7.2+ (default, Oct 4 2011, 20:06:09) [GCC 4.6.1] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> import zipfile >>> zip

[issue14310] Socket duplication for windows

2012-03-15 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' : -- nosy: +giampaolo.rodola ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue14295] PEP 417: adding mock module

2012-03-15 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' : -- nosy: +giampaolo.rodola ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue14309] Deprecate time.clock()

2012-03-15 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' : -- nosy: +giampaolo.rodola ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue14307] Make subclassing SocketServer simpler for non-blocking frameworks

2012-03-15 Thread Giampaolo Rodola'
Changes by Giampaolo Rodola' : -- nosy: +giampaolo.rodola ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue14309] Deprecate time.clock()

2012-03-15 Thread STINNER Victor
STINNER Victor added the comment: > time.clock() has been in use for ages in many many scripts. > We don't want to carelessly break all those. I don't want to remove the function, just mark it as deprecated to avoid confusion. It will only be removed from the next major Python. -- ___

[issue14313] zipfile does not unpack files from archive (files extracted have zero length)

2012-03-15 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: This ZIP file uses a compression method unsupported by Python: >>> z.getinfo('19A7B5A4.PKT').compress_type 6 which corresponds to "Imploded". Only "Stored" and "Deflated" are supported. Note that previous versions don't work either: they just happen to re

[issue14312] Convert PEP 7 to reStructuredText for readability purposes

2012-03-15 Thread Georg Brandl
Changes by Georg Brandl : -- Removed message: http://bugs.python.org/msg155870 ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue14312] Convert PEP 7 to reStructuredText for readability purposes

2012-03-15 Thread Georg Brandl
Georg Brandl added the comment: Yes, why not. Applied in c1fd4a5af1c5. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Un

[issue14312] Convert PEP 7 to reStructuredText for readability purposes

2012-03-15 Thread Georg Brandl
New submission from Georg Brandl : Yes, who not. Applied in 5d6ae5e01df6. -- nosy: +georg.brandl resolution: -> fixed status: open -> closed ___ Python tracker ___

[issue12758] time.time() returns local time instead of UTC

2012-03-15 Thread R. David Murray
R. David Murray added the comment: Thanks, Dylan. -- nosy: +r.david.murray resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed type: -> behavior ___ Python tracker __

[issue14127] add st_*time_ns fileds to os.stat(), add ns keyword to os.*utime*(), os.*utimens*() expects a number of nanoseconds

2012-03-15 Thread Larry Hastings
Larry Hastings added the comment: My revised patch, incorporating changes suggested by Antoine and Guido. -- Added file: http://bugs.python.org/file24859/larry.st_mtime_ns.patch.2.txt ___ Python tracker __

[issue12758] time.time() returns local time instead of UTC

2012-03-15 Thread Roundup Robot
Roundup Robot added the comment: New changeset 1559a82a3529 by R David Murray in branch '2.7': #12758: removing confusing mention of UTC from time.time description http://hg.python.org/cpython/rev/1559a82a3529 New changeset 5615d6b91b53 by R David Murray in branch '3.2': #12758: removing confus

<    1   2