[issue15331] Codecs docs should explain that the bytes-bytes shorthand aliases are missing

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: While you're right about that, the docs shouldn't be claiming they're available as long as that is the case. Updated the issue to make it clear this is a problem with the current docs and the change in the nature of the encode() and decode() methods for Python

[issue7475] codecs missing: base64 bz2 hex zlib hex_codec ...

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: FWIW it's, I've been thinking further about this recently and I think implementing this feature as builtin methods is the wrong way to approach it. Instead, I propose the addition of codecs.encode and codecs.decode methods that are type neutral (leaving any typ

[issue15339] document the threading "facts of life" in Python

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: Given the scope of the issue, a concurrent programming howto that lists some of the available options and the caveats associated with each of them seems worthwhile. -- nosy: +ncoghlan ___ Python tracker

[issue15349] SyntaxError b0rked grammar

2012-07-14 Thread Ztatik Light
New submission from Ztatik Light : SyntaxError: import * is not allowed in function '__init__' because it is contains a nested function with free variables ^ /s/"because it is contains"/"because it contains" -- components: Interpreter Core messages: 165437 nosy: Ztatik.Light prio

[issue14455] plistlib unable to read json and binary plist files

2012-07-14 Thread d9pouces
d9pouces added the comment: The plutil (Apple's command-line tool to convert plist files from a format to another) returns an error if you try to convert a XML plist with dates to JSON. -- ___ Python tracker

[issue7475] codecs missing: base64 bz2 hex zlib hex_codec ...

2012-07-14 Thread Ezio Melotti
Changes by Ezio Melotti : -- nosy: +ezio.melotti ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyt

[issue13866] {urllib, urllib.parse}.urlencode should not use quote_plus

2012-07-14 Thread samwyse
samwyse added the comment: Since no one else seems willing to do it, here's a patch that adds a 'quote_via' keyword parameter to the urlencode function. >>> import urllib.parse >>> query={"foo": "+ "} >>> urllib.parse.urlencode(query) 'foo=%2B+' >>> urllib.parse.urlencode(query, quote_via=urll

[issue15350] {urllib,urllib.parse}.urlencode.__doc__ is unclear

2012-07-14 Thread samwyse
New submission from samwyse : The doc string for url encode states: The query arg may be either a string or a bytes type. When query arg is a string, the safe, encoding and error parameters are sent to the quote_via function for encoding IMHO, this implies that the argument can be a

[issue15350] {urllib,urllib.parse}.urlencode.__doc__ is unclear

2012-07-14 Thread Ezio Melotti
Changes by Ezio Melotti : -- stage: -> needs patch type: behavior -> enhancement versions: -Python 2.6, Python 3.1 ___ Python tracker ___ __

[issue15327] Argparse: main arguments and subparser arguments indistinguishable

2012-07-14 Thread samwyse
samwyse added the comment: The Namespace object contains a combined list of all of the arguments, from both the main parser and the subparser. I don't see any way to resolve identically name augments without breaking a lot of code that relies on the current behavior. I would instead propose

[issue15280] Don't use builtins as variable names in urllib.request

2012-07-14 Thread Éric Araujo
Éric Araujo added the comment: We don’t do code cleanups for their own sake, but rather as part of a bug fix or feature addition. Please see #15137 for a longer explanation. -- nosy: +eric.araujo, r.david.murray, terry.reedy ___ Python tracker

[issue15311] Developer Guide doesn't get updated once a day

2012-07-14 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue15314] Use importlib instead of pkgutil in runpy

2012-07-14 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue15317] Source installation sets incorrect permissions for Grammar3.2.3.final.0.pickle

2012-07-14 Thread Éric Araujo
Éric Araujo added the comment: How did you configure and build? If you ran make as root it may explain this. -- nosy: +eric.araujo ___ Python tracker ___ __

[issue15280] Don't use builtins as variable names in urllib.request

2012-07-14 Thread Brian Brazil
Brian Brazil added the comment: This patch is a result of frustration encountered when debugging #15002. Not being able to use 'type' directly is rather annoying, so after figuring that bug out I set some time aside to make it easier for the next person. This could be considered a bug that urll

[issue15323] Provide target name in output message when Mock.assert_called_once_with fails

2012-07-14 Thread Éric Araujo
Éric Araujo added the comment: Nice idea! A small question: Why print 'time' in the message and not 'time.time'? -- nosy: +eric.araujo ___ Python tracker ___ _

[issue15328] datetime.strptime slow

2012-07-14 Thread Éric Araujo
Changes by Éric Araujo : -- components: +Extension Modules -None versions: +Python 3.4 -Python 2.7 ___ Python tracker ___ ___ Python-b

[issue15336] Argparse required arguments incorrectly displayed as optional arguments

2012-07-14 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.pyth

[issue15337] The cmd module incorrectly lists "help" as an undocumented command

2012-07-14 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +eric.araujo title: The cmd module incorrectly lists "help" as an undocument command -> The cmd module incorrectly lists "help" as an undocumented command ___ Python tracker _

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +brett.cannon, ncoghlan ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http:

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Éric Araujo
Éric Araujo added the comment: Sounds like a pkgutil-related issue to me. -- nosy: +eric.araujo ___ Python tracker ___ ___ Python-bug

[issue15299] pkgutil.ImpImporter(None).iter_modules() does not search sys.path

2012-07-14 Thread Éric Araujo
Changes by Éric Araujo : -- nosy: +brett.cannon, eric.araujo, ncoghlan ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubs

[issue5815] locale.getdefaultlocale() missing corner case

2012-07-14 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is yet some inconsistency: $ LANG=uk_ua.microsoftcp1251 ./python -c "import locale; print(locale.getdefaultlocale())" ('uk_UA', 'CP1251') $ LANG=uk_ua.microsoft-cp1251 ./python -c "import locale; print(locale.getdefaultlocale())" ('uk_UA', 'microsoft_c

[issue5815] locale.getdefaultlocale() missing corner case

2012-07-14 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Here is a complex patch for more careful locale parsing. -- Added file: http://bugs.python.org/file26380/locale_parse.patch ___ Python tracker ___

[issue15327] Argparse: main arguments and subparser arguments indistinguishable

2012-07-14 Thread samwyse
samwyse added the comment: One change and one minor problem with my suggestion. First, you don't need the second alias, since it's a prefix of the argument name. Also, HelpFormatter._format_actions_usage ends with a bit of code labeled "clean up separators for mutually exclusive groups"; it

[issue15230] runpy.run_path doesn't set __package__ correctly

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset 3b05cf877124 by Nick Coghlan in branch '3.2': Close #15230: runpy.run_path now sets __package__ correctly. Also refactored the runpy tests to use a more systematic approach http://hg.python.org/cpython/rev/3b05cf877124 New changeset 8a44e7c0fa30 b

[issue14935] PEP 384 Refactoring applied to _csv module

2012-07-14 Thread Robin Schreiber
Robin Schreiber added the comment: Added missing INCREF and DECREF inside the dealloc, and new methods of the types. -- Added file: http://bugs.python.org/file26381/csv_pep384_v1.patch ___ Python tracker

[issue15230] runpy.run_path doesn't set __package__ correctly

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4880aac5c665 by Nick Coghlan in branch '3.2': Issue #15230: Update runpy docs to clarify a couple of points that came up in this issue http://hg.python.org/cpython/rev/4880aac5c665 New changeset 416cd57d38cf by Nick Coghlan in branch 'default': Me

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: Indeed, pydoc relies on pkgutil.walk_packages to work out what to document, and that's broken currently due to the reliance on a non-standard importer API that isn't in PEP 302 (not even as an optional extension, like the get_filename() used by runpy) I'm not

[issue15351] Add to unittest.TestCase support for using context managers

2012-07-14 Thread Chris Jerdonek
New submission from Chris Jerdonek : The setUp() and tearDown() methods of unittest.TestCase are of course extremely useful. But sometimes one has set up and tear down functionality that one would like to apply in the form of an existing context manager (and that may be from an outside source

[issue15299] pkgutil.ImpImporter(None).iter_modules() does not search sys.path

2012-07-14 Thread Chris Jerdonek
Chris Jerdonek added the comment: In addition, before changing ImpImporter.iter_modules(), we should probably also add some tests of the method for values of self.path that do work (i.e. for when self.path is not None). The method is currently untested. I can work on adding tests for that ov

[issue15299] pkgutil.ImpImporter(None).iter_modules() does not search sys.path

2012-07-14 Thread Brett Cannon
Changes by Brett Cannon : -- nosy: -brett.cannon ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.p

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Brett Cannon
Brett Cannon added the comment: Ugh, I don't exactly love the idea of adding a method to any of importlib's finders simply because PJE didn't try to make this non-standard API part of PEP 302 or something. But basically pkgutil is worthless without doing something about this damn iter_modules

[issue15228] os.utime() docs not clear on behavior on nonexistant files

2012-07-14 Thread Larry Hastings
Larry Hastings added the comment: I don't think this needs clarifying. If you think the reference to "touch" currently only muddles the issue, let's remove it entirely. -- ___ Python tracker

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Georg Brandl
Georg Brandl added the comment: Not great, but that sounds reasonable. -- ___ Python tracker ___ ___ Python-bugs-list mailing list Un

[issue15337] The cmd module incorrectly lists "help" as an undocumented command

2012-07-14 Thread Roger Serwy
Roger Serwy added the comment: On 3.3.0b1 and 3.2 I get: (Cmd) help Documented commands (type help ): help I only see help under "Undocumented" with 2.7. It looks like this changeset f8c896ad787f never got backported to 2.7. This involves adding a

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Chris Jerdonek
Chris Jerdonek added the comment: I agree pkgutil is pretty much useless right now and deprecation worth considering. But isn't another option simply to change pkgutil's internals to provide its own iter_modules whenever it finds that method missing? This seems to be what it has done in the

[issue15280] Don't use builtins as variable names in urllib.request

2012-07-14 Thread Éric Araujo
Éric Araujo added the comment: > Not being able to use 'type' directly is rather annoying, so after figuring > that bug out I set > some time aside to make it easier for the next person. If you make a patch for #15002 then by all means rename “type” to “filetype” so that you can use the type f

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Chris Jerdonek
Chris Jerdonek added the comment: In Python 2.7, I just did this test: >>> import sys, pkgutil >>> for path in sys.path: ... print pkgutil.get_importer(path) And got only pkgutil.ImpImporter instances and imp.NullImporter objects. So even before, at least in the most common case, it looks l

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Brett Cannon
Brett Cannon added the comment: Right, you aren't getting ImpImporters because they are only used when a module doesn't define __loader__. But in Python 3.3, by default *all* modules get that attribute defined. And yes, we could either tweak pkgutil to recognize FileFinder and special-case i

[issue9522] xml.etree.ElementTree forgets the encoding

2012-07-14 Thread Serhiy Storchaka
Changes by Serhiy Storchaka : -- nosy: +storchaka ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.py

[issue15352] importlib.h should be regenerated when the marshaling code changes

2012-07-14 Thread Meador Inge
New submission from Meador Inge : Today I was hacking on a patch that changes the marshaling format for Code objects. When building the patch I was met with: ValueError: bad marshal data (unknown type code) make: *** [Lib/_sysconfigdata.py] Abort trap: 6 This is because the frozen impor

[issue15352] importlib.h should be regenerated when the marshaling code changes

2012-07-14 Thread Meador Inge
Meador Inge added the comment: Patch attached. -- keywords: +patch stage: needs patch -> patch review Added file: http://bugs.python.org/file26382/issue15352-v0.patch ___ Python tracker ___

[issue15351] Add to unittest.TestCase support for using context managers

2012-07-14 Thread R. David Murray
R. David Murray added the comment: Well, if you want to invoke the context in setup/teardown for some reason (as opposed to in the test methods themselves), you can do this: def setUp(self): self.foo = MyContextManager.__enter__() self.addCleanup(MyContextManager.__exit__()) Per

[issue15351] Add to unittest.TestCase support for using context managers

2012-07-14 Thread R. David Murray
R. David Murray added the comment: That should have been self.addCleanup(MyContextManager.__exit__) You could alternatively call __exit__() explicitly in tearDown, of course, but I believe addCleanup is a more reliable cleanup than tearDown. -- ___

[issue15352] importlib.h should be regenerated when the marshaling code changes

2012-07-14 Thread Antoine Pitrou
Antoine Pitrou added the comment: Looks good to me. It probably won't cover all cases (such as e.g. changing the bytecode format), but it's a good step forward. -- nosy: +pitrou ___ Python tracker ___

[issue15353] ld: library not found for -lpython3.3m because of wrong LDFLAGS_PYTHON

2012-07-14 Thread Jerry Jacobs
New submission from Jerry Jacobs : Dear all, I'm using python in a application (sigrok.org) and want to ship it as a framework with a .app folder. I'm building python-3.3b1 from source to a .framework. It is correctly compiled and installed in the given directory. Only the python-3.3.pc is i

[issue15353] ld: library not found for -lpython3.3m because of wrong LDFLAGS_PYTHON

2012-07-14 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- nosy: +hynek, ned.deily ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://m

[issue15353] ld: library not found for -lpython3.3m because of wrong LDFLAGS_PYTHON

2012-07-14 Thread Ned Deily
Changes by Ned Deily : -- assignee: ronaldoussoren -> ned.deily ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15351] Add to unittest.TestCase support for using context managers

2012-07-14 Thread Chris Jerdonek
Chris Jerdonek added the comment: Thanks for the interesting background and feedback. I was aware of the __enter__/__exit__ option but not the other information. And yes, I agree on the importance of trying and discussing any API before settling on it. The one I suggested was merely a point o

[issue14340] Update embedded copy of expat - fix security & crash issues

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset e4dc8be9a72f by Gregory P. Smith in branch 'default': Update the embedded copy of the expat XML parser to 2.1.0. It brings http://hg.python.org/cpython/rev/e4dc8be9a72f -- nosy: +python-dev ___ Python t

[issue14340] Update embedded copy of expat - fix security & crash issues

2012-07-14 Thread Gregory P. Smith
Gregory P. Smith added the comment: Updated in 3.3 for beta2. I'll leave it up to release managers to decide if they want to apply these updates for future 2.7 and 3.2 releases (trivial, just be sure to keep our one local modification adding the "#define XML_HAS_SET_HASH_SALT" to expat.h when

[issue14340] Update embedded copy of expat - fix security & crash issues

2012-07-14 Thread Gregory P. Smith
Gregory P. Smith added the comment: Reasons why it is a good idea to apply this change to 2.7.4 and 3.2.4: * Memory leak in poolGrow (CVE-2012-1148) * Resource leak in readfilemap.c (CVE-2012-1147) * Buffer over-read and crash in big2_toUtf8 (CVE-2009-3560) * Parser crash with special UTF-8 seq

[issue15354] _PyObject_LengthHint only accepts longs

2012-07-14 Thread Philip Jenvey
New submission from Philip Jenvey : The __length_hint__ optimization was broken a while ago for many iterators due to a bug introduced in 44c090c74202. It only accepts longs as valid hints, not ints This affects 2.6 too (but that's in security-only fix mode), but not 3.x -- assignee:

[issue15354] _PyObject_LengthHint only accepts longs

2012-07-14 Thread Philip Jenvey
Philip Jenvey added the comment: attached a fix for review -- keywords: +patch Added file: http://bugs.python.org/file26383/lengthhint-fix.diff ___ Python tracker ___ __

[issue15355] generator.__next__() docs should mention exception if already executing

2012-07-14 Thread Chris Jerdonek
New submission from Chris Jerdonek : I think the generator.__next__() documentation should say that it raises an exception if the generator is already executing: http://docs.python.org/dev/reference/expressions.html#generator.__next__ I don't think this is currently mentioned anywhere in the s

[issue15301] os.chown: OverflowError: Python int too large to convert to C long

2012-07-14 Thread Larry Hastings
Larry Hastings added the comment: It looks like #1747858 is another duplicate. Though arguably all these "dups" aren't really dups because I rewrote chown's argument parsing for 3.3. -- ___ Python tracker __

[issue15354] _PyObject_LengthHint only accepts longs

2012-07-14 Thread Benjamin Peterson
Benjamin Peterson added the comment: It's probably easier just to use PyNumber_Check. -- nosy: +benjamin.peterson ___ Python tracker ___

[issue15238] shutil.copystat should copy Linux extended attributes

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset 5f62c317c202 by Larry Hastings in branch 'default': - Issue #15238: shutil.copystat now copies Linux "extended attributes". http://hg.python.org/cpython/rev/5f62c317c202 -- nosy: +python-dev ___ Python t

[issue15354] _PyObject_LengthHint only accepts longs

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset 872afada51b0 by Benjamin Peterson in branch '2.7': allow any number to be returned from __length_hint__ (closes #15354) http://hg.python.org/cpython/rev/872afada51b0 -- nosy: +python-dev resolution: -> fixed stage: -> committed/rejected s

[issue15238] shutil.copystat should copy Linux extended attributes

2012-07-14 Thread Larry Hastings
Changes by Larry Hastings : -- resolution: -> fixed stage: needs patch -> committed/rejected status: open -> closed ___ Python tracker ___ __

[issue15301] os.chown: OverflowError: Python int too large to convert to C long

2012-07-14 Thread Larry Hastings
Larry Hastings added the comment: Here's a first cut at a patch. It's really just an update of Victor's patch to #4591 (done with his blessing). I tweaked it slightly; the parsing functions are now O& converter functions. I also added a reasonable unit test. Note however that the unit test

[issue15233] atexit: guarantee order of execution of registered functions?

2012-07-14 Thread Larry Hastings
Larry Hastings added the comment: Okay, I'll remove the ".. note". Checking in shortly. -- ___ Python tracker ___ ___ Python-bugs-li

[issue15233] atexit: guarantee order of execution of registered functions?

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset f8b520b6f654 by Larry Hastings in branch 'default': - Issue #15233: Python now guarantees that callables registered with http://hg.python.org/cpython/rev/f8b520b6f654 -- ___ Python tracker

[issue15233] atexit: guarantee order of execution of registered functions?

2012-07-14 Thread Larry Hastings
Larry Hastings added the comment: So, it's checked in to trunk. Shall I also backport to 2.7 and 3.2 as the issue suggests? -- ___ Python tracker ___ _

[issue15202] followlinks/follow_symlinks/symlinks flags unification

2012-07-14 Thread Larry Hastings
Larry Hastings added the comment: The .4 patches both LGTM, please commit! -- ___ Python tracker ___ ___ Python-bugs-list mailing lis

[issue15356] '\xa0' isspace returns true while compiling python on solaris 10 by users using gcc 3.4.6

2012-07-14 Thread zoupl
New submission from zoupl : Compile python (from 2.4.6 to version 2.6.8) on solaris 5.10 sparc using gcc 3.4.6. When using UTf-8, the \xa0 is a space. Howeve this is wrong. Version 2.7 is OK. >>> s = '\xa0' >>> assert s.strip() == s >>> import locale >>> locale.setlocale(locale.LC_ALL, 'en_US.

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: *sigh* And, of course, there's no meaningful regression test defined for pkgutil.walk_packages, which is why the test suite didn't pick this up :( Oh well, at least I have a clear place to start. -- assignee: -> ncoghlan __

[issue15357] Deprecate redundant pieces of pkgutil

2012-07-14 Thread Nick Coghlan
New submission from Nick Coghlan : To set the stage for fixing the regression reported in #15343, I'm going through and clearly marking the parts of pkgutil which should no longer be used now that the default import system is PEP 302 compliant. -- assignee: ncoghlan components: Library

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: Unassigning for the moment - I'm busy fighting fires in pkgutil (which is actually broken due to the import changes). If someone else has time to flesh out the method and data attribute documentation for the ipaddress classes, that would be great. -- a

[issue15356] '\xa0' isspace returns true while compiling python on solaris 10 by users using gcc 3.4.6

2012-07-14 Thread R. David Murray
R. David Murray added the comment: 2.6 only gets security fixes at this point, which this is not. -- nosy: +r.david.murray resolution: -> out of date stage: -> committed/rejected status: open -> closed type: -> behavior ___ Python tracker

[issue15356] '\xa0' isspace returns true while compiling python on solaris 10 by users using gcc 3.4.6

2012-07-14 Thread zoupl
zoupl added the comment: Could you please tell me the way to deal with this is version 2.7? -- ___ Python tracker ___ ___ Python-bugs

[issue12978] Figure out extended attributes on BSDs

2012-07-14 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis : -- nosy: +Arfrever ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

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

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset 6120cf695574 by Eli Bendersky in branch 'default': Close #1767933: Badly formed XML using etree and utf-16. Patch by Serhiy Storchaka, with some minor fixes by me http://hg.python.org/cpython/rev/6120cf695574 -- nosy: +python-dev resolutio

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

2012-07-14 Thread Roundup Robot
Roundup Robot added the comment: New changeset 51b5ee7cfa3b by Eli Bendersky in branch 'default': Issue #9458: clarify the documentation of ElementTree.write with regards to the type of the stream expected for a given encoding http://hg.python.org/cpython/rev/51b5ee7cfa3b -- nosy: +pyt

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

2012-07-14 Thread Eli Bendersky
Eli Bendersky added the comment: I agree with Serhiy that this is more of a documentation/understanding issue than a real bug. I've clarified the doc of ElementTree.write a bit to make it explicit what stream is expected for 'write'. -- assignee: -> docs@python components: +Documenta

[issue13823] xml.etree.ElementTree.ElementTree.write - argument checking

2012-07-14 Thread Eli Bendersky
Eli Bendersky added the comment: About (1): It's customary for Python to accept "truthful" values (like non-empty strings) as True. I see no harm in that. Strict type-checking to boolean True in each and every place is not necessary. About (2): Similarly, this isn't productive. ET may not k

[issue13378] ET: add custom namespaces to serialization methods

2012-07-14 Thread Eli Bendersky
Eli Bendersky added the comment: I'm changing the issue name to reflect the direction it's taken. Florent, once 3.3 is branched, could you please refresh the patch vs. head for 3.4 (don't forget the "what's new") and I'll review it for commit. -- title: Change the variable "nsmap" fro

[issue13378] ET: add custom namespaces to serialization methods

2012-07-14 Thread Eli Bendersky
Eli Bendersky added the comment: I'd also expand the doc of register_namespace to note what it should and shouldn't be used for (once this feature is added). -- ___ Python tracker

[issue15299] pkgutil.ImpImporter(None).iter_modules() does not search sys.path

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: The pkgutil import emulation is being deprecated in 3.3 However, I'll use this as useful input for any new walk_packages tests added while resolving #15343 -- resolution: -> wont fix stage: needs patch -> committed/rejected status: open -> closed

[issue15272] pkgutil.find_loader accepts invalid module names

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: I'll add a regression test for this as part of my purge of any internal usage of the pkgutil import emulation. -- ___ Python tracker ___ ___

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

2012-07-14 Thread Eli Bendersky
Eli Bendersky added the comment: I agree, but this will now be delayed to 3.4, since it's not a bug-fixing change in functionality. P.S. is there any way to create a test for it? -- assignee: -> eli.bendersky priority: normal -> low type: -> behavior versions: -Python 3.3

[issue15083] Rewrite ElementTree tests in a cleaner and safer way

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- versions: -Python 3.3 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mai

[issue15352] importlib.h should be regenerated when the marshaling code changes

2012-07-14 Thread Eric Snow
Eric Snow added the comment: FYI: the .pyc magic number is now built/kept in Lib/importlib/_bootstrap.py, so updates to it will trigger a rebuild of frozen importlib during make. -- nosy: +eric.snow ___ Python tracker

[issue15343] "pydoc -w " writes out page with empty "Package Contents" section

2012-07-14 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis : -- nosy: +Arfrever ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscri

[issue10908] Improvements to trace._Ignore

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- nosy: -eli.bendersky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue9914] trace/profile conflict with the use of sys.modules[__name__]

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- nosy: -eli.bendersky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.

[issue10342] trace module cannot produce coverage reports for zipped modules

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- nosy: -eli.bendersky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue9325] Add an option to pdb/trace/profile to run library module as a script

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- nosy: -eli.bendersky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.

[issue14332] Better explain "junk" concept in difflib doc

2012-07-14 Thread Eli Bendersky
Eli Bendersky added the comment: ping -- ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail.python.or

[issue13386] Document documentation conventions for optional args

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- nosy: -eli.bendersky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue15352] importlib.h should be regenerated when the marshaling code changes

2012-07-14 Thread Eric Snow
Eric Snow added the comment: What I mean is, shouldn't changes to marshal have an accompanying bump to the pyc magic number? -- ___ Python tracker ___ _

[issue10685] trace does not ignore --ignore-module

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- nosy: -eli.bendersky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue13997] Clearly explain the bare minimum Python 3 users should know about Unicode

2012-07-14 Thread Eli Bendersky
Changes by Eli Bendersky : -- nosy: -eli.bendersky ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: http://mail

[issue15314] Use importlib instead of pkgutil in runpy

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: OK, the way I plan to tackle this is to actually redirect the pkgutil APIs to importlib (rather than using the private import emulation). The reason I'm going to tackle it like this is that there are some assumptions pkgutil deals with that importlib doesn't. S

[issue15314] Use importlib instead of pkgutil in runpy

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: Oh, special - importlib.find_loader() currently expects every module to have a __loader__ attribute, but there's at least one that doesn't: __main__. Guess I'll be tweaking it to handle that case more gracefully after all :) --

[issue14332] Better explain "junk" concept in difflib doc

2012-07-14 Thread Terry J. Reedy
Terry J. Reedy added the comment: I guess I should try to come up with something that is an improvement, even if not perfect. -- ___ Python tracker ___

[issue15314] Use importlib instead of pkgutil in runpy

2012-07-14 Thread Nick Coghlan
Nick Coghlan added the comment: Ah, __main__, thou art such a special beast. Here's my current plan: 1. __main__ will be initialised with __loader__ set to BuiltinImporter. This covers cases like the interactive prompt or execution of stdin where there is no source code available for __main_