[issue15248] In "TypeError: 'tuple' object is not callable", explain that a comma may be missing

2012-07-05 Thread Ben Longbons
Ben Longbons added the comment: This kind of "debug your code" is the kind of thing I've gotten used to from the Clang C/C++ compiler. Granted, compiled languages have an advantage here, but enough residual information remains for the interpreter at runtime. And I am in no way suggesting that

[issue14377] Modify serializer for xml.etree.ElementTree to allow forcing the use of long tag closing

2012-07-05 Thread Eli Bendersky
Eli Bendersky added the comment: I see no harm in modifying the signature of the private _serialize_* functions to accept another argument or dict of options. -- ___ Python tracker ___

[issue14988] _elementtree: Raise ImportError when importing of pyexpat fails

2012-07-05 Thread Eli Bendersky
Changes by Eli Bendersky : -- components: +Library (Lib) stage: -> test needed versions: +Python 3.4 -Python 3.2 ___ Python tracker ___ _

[issue9458] xml.etree.ElementTree.ElementTree.write(): encoding handling problems

2012-07-05 Thread Eli Bendersky
Eli Bendersky added the comment: Please make sure that the patch(es) apply cleanly to 3.3, since this is the version I'll be focusing on. -- ___ Python tracker ___ _

[issue1767933] Badly formed XML using etree and utf-16

2012-07-05 Thread Eli Bendersky
Eli Bendersky added the comment: Serhiy, note that _SimpleElementPath is now gone in 3.3, since ElementPath.py is always there in stdlib. Could you update the patch to reflect this? Another thing. I'm trying really hard to phase out the doctest tests of etree, replacing them with unittest-bas

[issue14202] The docs of xml.dom.pulldom are almost nonexistent

2012-07-05 Thread Eli Bendersky
Changes by Eli Bendersky : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue15009] urlsplit can't round-trip relative-host urls.

2012-07-05 Thread Buck Golemon
Buck Golemon added the comment: Let's examine x:// absolute-URI = scheme ":" hier-part [ "?" query ] hier-part = "//" authority path-abempty So this is okay if authority and path-abempty can both be empty strings. authority = [ userinfo "@" ] host [ ":" port ] host = IP-lite

[issue15231] update PyPI upload doc to say --no-raw passed to rst2html.py

2012-07-05 Thread Chris Jerdonek
Changes by Chris Jerdonek : -- keywords: +patch stage: -> patch review Added file: http://bugs.python.org/file26268/issue-15231-1.patch ___ Python tracker ___ __

[issue15248] In "TypeError: 'tuple' object is not callable", explain that a comma may be missing

2012-07-05 Thread Steven D'Aprano
Steven D'Aprano added the comment: I think this suggested enhancement is unreasonable and of limited usefulness, and even if it were useful, too specialised to bother with. The obvious message is badly misleading. When I read this: TypeError: 'tuple' object is not callable, a comma may be mis

[issue15246] Line coverage for collectionts.abc.Set

2012-07-05 Thread James King
James King added the comment: How about a working test instead? Let me know if it looks right. -- Added file: http://bugs.python.org/file26267/set_abc_coverage.patch ___ Python tracker

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread João Bernardo
Changes by João Bernardo : Added file: http://bugs.python.org/file26266/ast.py_tests_doc.diff ___ Python tracker ___ ___ Python-bugs-list mail

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread Éric Araujo
Éric Araujo added the comment: No, the rst documentation is maintained manually. Look for versionchanged in the doc source files or the documentation about writing documentation to see how to document the new argument (and new supported Ellipsis literal). --

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread João Bernardo
João Bernardo added the comment: Just to be sure: What's a doc update? The `.rst` files are updated automatically with the doc strings? The adding another argument should require a: "Changed in version 3.x: Accepts a second argument ..." ? -- ___ P

[issue15257] Misc/.gdbinit:pystack is too brittle

2012-07-05 Thread Jesús Cea Avión
Changes by Jesús Cea Avión : -- nosy: +jcea ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread Éric Araujo
Éric Araujo added the comment: Thanks for the patch. It looks good to me, but I think that adding support for Ellipsis and adding a new parameter to allow extra names are two different requests, but someone more knowledgeable than me about AST may judge differently. My rationale is that sup

[issue15250] document that filecmp.dircmp comparisons are "shallow"

2012-07-05 Thread Chris Jerdonek
Changes by Chris Jerdonek : -- keywords: +patch stage: needs patch -> patch review Added file: http://bugs.python.org/file26265/issue15250-1.patch ___ Python tracker ___

[issue15261] os.stat(fd) crashes on Windows if fd does not exist

2012-07-05 Thread Richard Oudkerk
Richard Oudkerk added the comment: This can probably be fixed by using _PyVerify_fd(). -- ___ Python tracker ___ ___ Python-bugs-list

[issue15261] os.stat(fd) crashes on Windows if fd does not exist

2012-07-05 Thread Richard Oudkerk
New submission from Richard Oudkerk : In Python 3.3 (but not earlier) os.stat() is documented to work with file descriptors. (os.path.exists() also works with fds since it is implemented in terms of os.stat(), although that is *not* documented.) However, on Windows if fd is not open then os.s

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread João Bernardo
Changes by João Bernardo : Added file: http://bugs.python.org/file26264/ast.py_with_tests.diff ___ Python tracker ___ ___ Python-bugs-list mai

[issue15260] Mention how to order Misc/NEWS entries

2012-07-05 Thread Chris Jerdonek
New submission from Chris Jerdonek : I think it would help if the "Commit Messages and NEWS Entries" subsection of the Developer's Guide said something about where in the ordering new Misc/NEWS entries should be added (e.g. at the top or bottom or by importance): http://docs.python.org/devguid

[issue15259] "Helping with Documentation" references missing dailybuild.py

2012-07-05 Thread Chris Jerdonek
New submission from Chris Jerdonek : The intro to the "Helping with Documentation" section of the Developer's Guide-- http://docs.python.org/devguide/docquality.html#helping-with-documentation includes a reference to a Doc/tools/dailybuild.py script, but this script does not seem to exist in t

[issue15257] Misc/.gdbinit:pystack is too brittle

2012-07-05 Thread rian
Changes by rian : -- versions: +Python 3.2, Python 3.3, Python 3.4 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscrib

[issue15257] Misc/.gdbinit:pystack is too brittle

2012-07-05 Thread rian
Changes by rian : -- components: +Demos and Tools -None ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://

[issue15258] argparse documentation: Improve optparse section regarding allow_interspersed_args

2012-07-05 Thread Nefarious CodeMonkey, Jr.
New submission from Nefarious CodeMonkey, Jr. : It was not obvious from the documentation on argparse how to emulate the optparse.OptionParser.allow_interspersed_args feature. Please add something like the following to the section titled "Upgrading optparse code" (see: http://docs.python.org/

[issue15257] Misc/.gdbinit:pystack is too brittle

2012-07-05 Thread rian
New submission from rian : the `pystack`, `pystackv`, and `printframe` macros in the sample gdbinit file distributed with python are too fragile. this patch (which relies on gdb 7) is much more robust. -- components: None files: mypatch.diff keywords: patch messages: 164701 nosy: rian

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: Ah right, that's confusing indeed... Unit tests and doc updates are needed though. -- ___ Python tracker ___ ___

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread João Bernardo
João Bernardo added the comment: Ellipsis in this context is `_ast.Ellipsis`, not the original one... There's no TypeError there as `_ast.Ellipsis` is a class. -- ___ Python tracker __

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc added the comment: I like the 'safe_names' idea, but is this patch supposed to work? >>> isinstance(None, Ellipsis) TypeError: isinstance() arg 2 must be a type or tuple of types -- nosy: +amaury.forgeotdarc ___ Python tracker

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- keywords: +needs review stage: -> test needed ___ Python tracker ___ ___ Python-bugs-list mailing list Un

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread João Bernardo
Changes by João Bernardo : -- keywords: +patch Added file: http://bugs.python.org/file26262/ast.py.diff ___ Python tracker ___ ___ Pyt

[issue15243] Misleading documentation for __prepare__

2012-07-05 Thread Daniel Urban
Daniel Urban added the comment: Actually the docs contained a similar sentence ("If the metaclass has a :meth:`__prepare__` attribute (usually implemented as a class or static method), ..."), but it was removed in befd56673c80 when Nick rewrote this section. -- _

[issue15243] Misleading documentation for __prepare__

2012-07-05 Thread William Schwartz
William Schwartz added the comment: Daniel, Good point. However it would still be useful for documentation to point out that __prepare__ can be passed the metaclass as the implicit first argument by being decorated by classmethod. I'll post a small patch when I get a chance to add a sentence

[issue15020] default value for progname in pythonrun.c should be python3 for Python 3

2012-07-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: This should be fixed now. Thanks! -- resolution: -> fixed stage: -> committed/rejected status: open -> closed ___ Python tracker ___

[issue15256] Typo in error message

2012-07-05 Thread Ned Batchelder
Changes by Ned Batchelder : -- nosy: +nedbat ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python

[issue15020] default value for progname in pythonrun.c should be python3 for Python 3

2012-07-05 Thread Roundup Robot
Roundup Robot added the comment: New changeset c97d78415f5a by Antoine Pitrou in branch '3.2': Issue #15020: The program name used to search for Python's path is now "python3" under Unix, not "python". http://hg.python.org/cpython/rev/c97d78415f5a New changeset 61e6ac40c816 by Antoine Pitrou i

[issue15256] Typo in error message

2012-07-05 Thread Marc Abramowitz
New submission from Marc Abramowitz : >From a failing unit test with coverage.py, I noticed what seems to be a slight >typo in the error message when a module cannot be imported: diff -r 1186d68715cc Lib/imp.py --- a/Lib/imp.pyWed Jul 04 19:33:45 2012 -0700 +++ b/Lib/imp.pyThu J

[issue15020] default value for progname in pythonrun.c should be python3 for Python 3

2012-07-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: Okay, that's convincing enough. Besides, I don't think it has ever worked for Windows, since it misses the adding of a ".exe" suffix. -- ___ Python tracker __

[issue15020] default value for progname in pythonrun.c should be python3 for Python 3

2012-07-05 Thread Joshua Cogliati
Joshua Cogliati added the comment: > Joshua, if you are embedding Python, why don't you simply call Py_SetPath to > set the search path appropriately? Or is it not enough? (I've lost memory of > the mazy details of how we calculate paths :-S). Setting Py_SetPath manually would basically requi

[issue8996] Add a default role to allow writing bare `len` instead of :func:`len`

2012-07-05 Thread Éric Araujo
Éric Araujo added the comment: > for example, as a result of documentation merge it both > :func:`someref` and :class:`someref` can appear I think this would cause a warning from Sphinx, as all class/meth/func/mod/etc roles look up in the same namespace (what Georg said). Benjamin is -1 for ex

[issue15255] spam / garbage report

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- title: glose_Fb -> spam / garbage report ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscr

[issue15255] glose_Fb

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : Removed file: http://bugs.python.org/file26261/Fb.init.js ___ Python tracker ___ ___ Python-bugs-list mailing list Un

[issue15255] glose_Fb

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: -andisthermal555 resolution: -> invalid stage: -> committed/rejected status: open -> closed type: security -> ___ Python tracker ___ ___

[issue15248] In "TypeError: 'tuple' object is not callable", explain that a comma may be missing

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo title: In "TypeError: 'tuple' object is not callable", suggest a comma. -> In "TypeError: 'tuple' object is not callable", explain that a comma may be missing ___ Python tracker

[issue10716] Modernize pydoc to use better HTML and separate CSS

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- assignee: lukasz.langa -> eric.araujo stage: -> patch review versions: +Python 3.4 -Python 3.3 ___ Python tracker ___ ___

[issue10716] Modernize pydoc to use better HTML and separate CSS

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- title: Modernize pydoc to use CSS -> Modernize pydoc to use better HTML and separate CSS ___ Python tracker ___ _

[issue15020] default value for progname in pythonrun.c should be python3 for Python 3

2012-07-05 Thread Antoine Pitrou
Antoine Pitrou added the comment: Hmm, actually, there is a potential problem. While "python3" is the official binary under POSIX, under Windows it is "python" (well, "python.exe"). Joshua, if you are embedding Python, why don't you simply call Py_SetPath to set the search path appropriately?

[issue15255] glose_Fb

2012-07-05 Thread andisthermal
New submission from andisthermal : This automatic page generator is the easiest way to create beautiful pages for all of your projects. Author your page content here using GitHub Flavored Markdown, select a template crafted by a designer, and publish. After your page is generated, you can chec

[issue15253] xmlrpclib.ServerProxy does not support 2-tuple value for uri parameter

2012-07-05 Thread Martin v . Löwis
Martin v. Löwis added the comment: The situation is now much different from what it was for #1561. Python 2 is closed for anything but bug fixes; this rules out code cleanup as well. -- ___ Python tracker ___

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-07-05 Thread Brad Tilley
"Additionally, shutil.copyfile procedure seems to have a problem with symlinks that could result in the corruption of content of any file on filesystem (in favorable conditions)." --- Does the shutil.copyfile corruption issue impact Python 2.6? And, what sort of "favorable conditions" need to exi

[issue15020] default value for progname in pythonrun.c should be python3 for Python 3

2012-07-05 Thread Joshua Cogliati
Joshua Cogliati added the comment: > Joshua: what command did you run under strace? A program I created that embeds python3. I could create a minimum piece of code that triggered the bug if needed. > Maybe it would be better to use L"python3.2" for Python 3.2 and L"python3.3" > for Python 3

[issue15243] Misleading documentation for __prepare__

2012-07-05 Thread Daniel Urban
Daniel Urban added the comment: __prepare__ is not implicitly a staticmethod, and it is called exactly as documented (also in types.prepare_class). There is no implicit first argument because the method is called on the (meta)class object. -- ___ P

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo, georg.brandl ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: ht

[issue15243] Misleading documentation for __prepare__

2012-07-05 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo, ncoghlan stage: -> needs patch versions: +Python 3.2 ___ Python tracker ___ ___ Pytho

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread João Bernardo
João Bernardo added the comment: Of course `nan` and `inf` are part of the syntax! The `ast.parse` function recognize them as `Name`. So that works: >>> ast.dump(ast.parse('True')) "Module(body=[Expr(value=Name(id='True', ctx=Load()))])" >>> ast.dump(ast.parse('inf')) "Module(body=[Expr(val

[issue15242] PyImport_GetMagicTag() should use the same const char * as sys.implementation.cache_tag

2012-07-05 Thread Brett Cannon
Brett Cannon added the comment: tl;dr: "==", not "is" Shouldn't tl;dr go first, else it seems a little pointless since I already read the whole thing. At which point the tl;dr is really just a summary of what I just read, not a "didn't read" line. Just being pedantic. =) --

[issue15254] 08 is invalid token in lists.

2012-07-05 Thread Tim Golden
Changes by Tim Golden : -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.p

[issue15254] 08 is invalid token in lists.

2012-07-05 Thread Tim Golden
Tim Golden added the comment: A "0" prefix to a number is taken by Python 2.x to introduce a series of octal (base 8) digits. You can't have 8 in base 8 so the number (and anything higher) is rejected. -- nosy: +tim.golden resolution: -> rejected stage: -> committed/rejected __

[issue15254] 08 is invalid token in lists.

2012-07-05 Thread Chris Wright
New submission from Chris Wright : Python 2.6.6 tk 8.5 Idle 2.6.6 I was trying to generate a multidimensional list, and my test list kept giving errors highlighting 08 as an invalid token. >>> cube = >>> [[[01,02,03],[04,05,06],[07,08,09]],[[11,12,13],[14,15,16],[17,18,19]],[[21,22,3],[24,25,

[issue15252] Delivery reports about your e-mail

2012-07-05 Thread Benjamin Peterson
Changes by Benjamin Peterson : -- resolution: -> invalid status: open -> closed ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue15252] Delivery reports about your e-mail

2012-07-05 Thread Bob Ippolito
Bob Ippolito added the comment: I doubt it, it's more likely that this email came from somewhere else with my address. On Thursday, July 5, 2012, Larry Hastings wrote: > > Larry Hastings > added the comment: > > What fresh hell is this? Bob, do you have a virus or something? > > -- >

[issue15245] ast.literal_eval fails on some literals

2012-07-05 Thread Mark Dickinson
Mark Dickinson added the comment: > I don't think literal_eval should handle anything which is not syntax. +1 -1 on supporting 'inf' and 'nan' -0 on supporting 'Ellipsis' or '...'; seems harmless, but I don't really see the point. -- ___ Python tr

[issue15253] xmlrpclib.ServerProxy does not support 2-tuple value for uri parameter

2012-07-05 Thread Vincent Pelletier
Vincent Pelletier added the comment: Then I guess SafeTransport should be cleaned to remove its dead code (tuple host handling), and the class you link to should be included (in spirit if not verbatim) in xmlrpclib. Also, sorry, I realized after posting that this bug is a dupe of #1581. But t

[issue15253] xmlrpclib.ServerProxy does not support 2-tuple value for uri parameter

2012-07-05 Thread Martin v . Löwis
Martin v. Löwis added the comment: This is not a bug; the uri parameter is documented as an URI. Your report can be considered as a feature request (for supporting non-URI values for the uri parameter), however, Python 2 is closed for new features, so this could only be added for 3.x. Closin

[issue15253] xmlrpclib.ServerProxy does not support 2-tuple value for uri parameter

2012-07-05 Thread Vincent Pelletier
New submission from Vincent Pelletier : SafeTransport class supports a 2-tuple as uri, in order to pass x509 parameters to httplib.HTTPSConnection . xmlrpclib.ServerProxy.__init__ fails when given such tuple, because it calls: urllib.splittype(uri) without checking uri type first. Minimal tes

[issue15242] PyImport_GetMagicTag() should use the same const char * as sys.implementation.cache_tag

2012-07-05 Thread Larry Hastings
Larry Hastings added the comment: Sorry for the pedantry, but: I read the title of this bug as wanting these two values to be the exact same pointer. If you're talking about putting a constant string in a header file, you'll get an (identical) copy of that string in every .o that references

[issue15252] Delivery reports about your e-mail

2012-07-05 Thread Larry Hastings
Larry Hastings added the comment: What fresh hell is this? Bob, do you have a virus or something? -- nosy: +larry ___ Python tracker ___ ___

[issue15252] Delivery reports about your e-mail

2012-07-05 Thread Larry Hastings
Changes by Larry Hastings : -- nosy: -larry ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python