[issue15471] importlib's __import__() argument style nit

2012-08-06 Thread Roundup Robot
Roundup Robot added the comment: New changeset 4240282a9f4a by Brett Cannon in branch 'default': Issue #15471: Don't use mutable object as default values for the http://hg.python.org/cpython/rev/4240282a9f4a -- nosy: +python-dev ___ Python tracker

[issue15471] importlib's __import__() argument style nit

2012-08-06 Thread Brett Cannon
Changes by Brett Cannon br...@python.org: -- resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15471 ___

[issue15471] importlib's __import__() argument style nit

2012-08-06 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: On Aug 05, 2012, at 11:50 PM, Brett Cannon wrote: I went with Barry's approach but made it compatible with PEP 8 (bad, FLUFL; no unneeded parens!). I actually think I picked that up from the big guy himself, but I could be misremembering. ;) --

[issue15471] importlib's __import__() argument style nit

2012-08-05 Thread Brett Cannon
Brett Cannon added the comment: Attached is a patch that drops all mutable default arguments to __import__() and updates the docs. I went with Barry's approach but made it compatible with PEP 8 (bad, FLUFL; no unneeded parens!). I also ignored the locals argument since __import__ doesn't even

[issue15471] importlib's __import__() argument style nit

2012-08-05 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15471 ___

[issue15471] importlib's __import__() argument style nit

2012-08-05 Thread Meador Inge
Meador Inge added the comment: LGTM. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15471 ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue15471] importlib's __import__() argument style nit

2012-08-05 Thread Georg Brandl
Georg Brandl added the comment: Looks good and safe to me. +1. -- assignee: georg.brandl - brett.cannon ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15471 ___

[issue15471] importlib's __import__() argument style nit

2012-07-31 Thread Barry A. Warsaw
Barry A. Warsaw added the comment: On Jul 30, 2012, at 04:39 AM, Meador Inge wrote: Meador Inge added the comment: How about the attached? What about something like: globals = ({} if globals is None else globals) and similarly for locals? --

[issue15471] importlib's __import__() argument style nit

2012-07-29 Thread Meador Inge
Meador Inge added the comment: How about the attached? -- keywords: +patch nosy: +meador.inge stage: - patch review type: - behavior Added file: http://bugs.python.org/file26592/issue-15471.patch ___ Python tracker rep...@bugs.python.org

[issue15471] importlib's __import__() argument style nit

2012-07-27 Thread Barry A. Warsaw
New submission from Barry A. Warsaw ba...@python.org: Very minor style nit. In general, it's not considered good style to use mutable objects in default argument values. importlib's _bootstrap.__import__() does just this for its globals, locals, and fromlist arguments. The implementation