[issue11660] closure with too few cells segfaults

2011-03-24 Thread Eric Snow
New submission from Eric Snow ericsnowcurren...@gmail.com: While perhaps esoteric, it looks like exec'ing a code object that has freevars, using a closure that has too few cells causes a segfault. I believe the problem is around line 3276 of ceval.c at the PyTuple_GET_ITEM call

[issue11660] closure with too few cells segfaults

2011-03-24 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: I'm hoping to release it this week. Nick helped be a bunch with it during pycon sprints. I basically took call_function in ceval.c and got it working for arbitrary code blocks and exposed it as exec_closure to look like exec. On Thu

[issue11660] closure with too few cells segfaults

2011-03-24 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: It's a C function that for now I have in an extension module. If it turns out to be useful I am going to try to get it put into the builtins, but I don't want to get ahead of myself. -- Added file: http://bugs.python.org

[issue11988] special method lookup docs don't address some important details

2011-05-03 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: In 2.7 I get the following (if Y does not inherit from object): print('res:', 1 in y) ('X contains:', 1) ('res:', False) This makes sense with old style classes. With Y(object): print('res:', 1 in y) Y iter ('res:', True

[issue12064] unexpected behavior with exception variable

2011-05-12 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Duplicate of issue8130. When an exception has been assigned using as target, it is cleared at the end of the except clause. [1] See: [1] http://docs.python.org/py3k/reference/compound_stmts.html#the-try-statement [2] http

[issue12128] Allow `abc.abstractproperty` to be overridden by a data attribute

2011-05-20 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Wow! I was literally working on this problem yesterday. The abstract check is done at instantiation time (in object.__new__, typeobject.c). So as it stands __new__ has no way to validate that all your abstract properties have been

[issue12128] Allow `abc.abstractproperty` to be overridden by a data attribute

2011-05-20 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: As far as I have found, there isn't a way to make it work implicitly without changing object.__new__. I just posted some of the approaches I could think of to python-list: http://mail.python.org/pipermail/python-list/2011-May/1272604

[issue13124] Add Running a Build Slave page to the devguide

2011-10-07 Thread Eric Snow
New submission from Eric Snow ericsnowcurren...@gmail.com: Here's a patch to add a page to the devguide on running a build slave. I copied pretty liberally from the wiki (http://wiki.python.org/moin/BuildBot). That page may or may not be up to date (I don't know), so the bulk of this new

[issue13124] Add Running a Build Slave page to the devguide

2011-10-07 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Great feedback! Keep in mind that nearly all the content in my patch is pulled unedited from either the wiki page and the python-dev thread I mentioned. I'll work on cleaning it up when I get a chance (probably after Wednesday's PyCon

[issue8087] Unupdated source file in traceback

2011-10-10 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8087 ___ ___ Python-bugs-list

[issue13177] Avoid chained exceptions in lru_cache

2011-10-14 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Could you just cancel the chained exception? try: {}[asdf] ... except KeyError: ... try: raise Exception() ... except Exception as x: ... x.__cause__ = None ... x.__context__ = None ... x

[issue13187] relative imports don't work when circular

2011-10-15 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13187 ___ ___ Python-bugs-list

[issue415492] Compiler generates relative filenames

2011-10-16 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue415492 ___ ___ Python-bugs

[issue13192] ImportError silences low-level OS errors

2011-10-16 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13192 ___ ___ Python-bugs-list

[issue13192] ImportError silences low-level OS errors

2011-10-17 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Are you suggesting raising the OSError (or something else) rather than an ImportError? If so, would it make sense to chain the exception instead. That way the existing code that expects ImportError continues to work, while still

[issue12915] Add inspect.locate and inspect.resolve

2011-10-19 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12915 ___ ___ Python-bugs-list

[issue13124] Add Running a Build Slave page to the devguide

2011-10-19 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Per Ezio's and Stefan's feedback I cleaned things up a little: * consolidated on Buildbot * clarified the meaning of the standard development toolchain * % changed to $ * cleaned up the network ports section * removed a bunch of outdated

[issue13124] Add Running a Build Slave page to the devguide

2011-10-19 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: Added file: http://bugs.python.org/file23479/devguide-buildbots-2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13124

[issue13243] _Py_identifier should be _Py_IDENTIFER

2011-10-22 Thread Eric Snow
New submission from Eric Snow ericsnowcurren...@gmail.com: Looks like Parser/asdl_c.py did not get all the way updated when _Py_identifier switched over to _Py_IDENTIFER. I've included a patch that fixes it (though it's relatively trivial). With this fix I did not notice any further problems

[issue10977] Concrete object C API considered harmful to subclasses of builtin types

2011-11-05 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10977 ___ ___ Python-bugs-list

[issue13361] getLogger does not check its argument

2011-11-07 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: FYI, the following changesets were also for this issue. They had the wrong issue number (#13661, which doesn't actually exist so no big deal), which is why they didn't show up in this issue automatically. New changeset 5f3b7528b144

[issue13387] add exact_type argument to assertIsInstance

2011-11-12 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: @msg147513 Why don't you just write self.assertIs(type(myobj), sometype) +1 -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13387

[issue13386] Document documentation conventions for optional args

2011-11-14 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: 4) she got annoyed that two completely different notations where used for two very close concepts This is a good point, and we are trying to move to the arg=default notation. Unfortunately there are still places that use the old

[issue2775] Implement PEP 3108

2011-11-14 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: For the stat module in the Obsolete section[1], should the entry be updated to indicate that the module was left alone (see issue 2874)? Would it be worth having the Merging C and Python Impl... section[2] include a reference to PEP 399

[issue13386] Document documentation conventions for optional args

2011-11-15 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Me too. (Can you give the #ids of these other issues?) #13012 is the one that I was thinking of (msg144328 specifically). However, I'm sure there was one more recently (which I can't find now

[issue13386] Document documentation conventions for optional args

2011-11-15 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: @msg147671 +1 -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13386 ___ ___ Python-bugs

[issue13411] Hashable memoryviews

2011-11-15 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13411 ___ ___ Python-bugs-list

[issue13429] provide __file__ to extension init function

2011-11-18 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13429 ___ ___ Python-bugs-list

[issue10621] 1 + 2j -- (1 + 2j) and not (1+2j)

2011-11-21 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: @eric.smith: +1 @Retro: If you are intent on pushing this, please take it to python-id...@python.org. However, judging from the response in this ticket and #10562, you won't get much traction. -- nosy: +eric.snow

[issue10562] Change 'j' for imaginary unit into an 'i'

2011-11-21 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: @brian.curtin: +1 @Retro: as noted in #10621, please take this to python-id...@python.org -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10562

[issue13402] Document absoluteness of sys.executable

2011-11-21 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13402 ___ ___ Python-bugs-list

[issue13445] Enable linking the module pysqlite with Berkeley DB SQL instead of SQLite

2011-11-21 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13445 ___ ___ Python-bugs-list

[issue12618] py_compile cannot create files in current directory

2011-11-21 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12618 ___ ___ Python-bugs-list

[issue10854] Output .pyd name in error message of ImportError when DLL load fails

2011-11-22 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue10854 ___ ___ Python-bugs-list

[issue13224] Change str(x) to return only __qualname__ for some types

2011-11-22 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13224 ___ ___ Python-bugs-list

[issue13474] Mention of -m Flag Missing From Doc on Execution Model

2011-11-24 Thread Eric Snow
New submission from Eric Snow ericsnowcurren...@gmail.com: The doc on code execution[1] leaves out mention of the -m flag. Seems like it belongs there too. [1] Doc/reference/executionmodel.rst -- assignee: docs@python components: Documentation messages: 148288 nosy: docs@python

[issue13475] Add '-p'/'--path0' command line option to override sys.path[0] initialisation

2011-11-24 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13475 ___ ___ Python-bugs-list

[issue13475] Add '-p'/'--path0' command line option to override sys.path[0] initialisation

2011-11-24 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: +1 Both the -p and --nopath0 would be great additions and a good match for PEP 395. So -p . would be equivalent to the current implicit sys.path[0] initialization, right? Would any other effects happen with -p than sys.path[0

[issue8754] quote bad module name in ImportError-like messages

2011-11-25 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8754 ___ ___ Python-bugs-list

[issue13475] Add '-p'/'--path0' command line option to override sys.path[0] initialisation

2011-11-25 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: The current behavior is an implicit -p ., which causes all sorts of hard-to-figure-out problems, most of which PEP 395 is rightly trying to fix. I'm suggesting that the next step would be to make --nopath0 the default (rendering

[issue12307] Inconsistent formatting of section titles in PEP 0

2011-11-25 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Éric has addressed this in http://hg.python.org/peps/rev/6c7415a4f0f3 (thanks Éric). Do the docs for python.org have to be manually rebuilt or is that on a cron? -- ___ Python tracker rep

[issue13475] Add '-p'/'--path0' command line option to override sys.path[0] initialisation

2011-11-25 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: First of all, I don't want Nick's proposal in this issue (the -p and --nopath0 flags) to be misunderstood because of me. His is a great idea that will make a really useful shortcut available and will _not_ change any current behavior

[issue13475] Add '-p'/'--path0' command line option to override sys.path[0] initialisation

2011-11-25 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Yeah, the more I think about it, the more I agree it's Python 4 fodder. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13475

[issue13457] Use repr(module name) ImportErrors

2011-11-26 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13457 ___ ___ Python-bugs-list

[issue12307] Inconsistent formatting of section titles in PEP 0

2011-11-26 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Thanks, Éric. That's what I figured. I asked because the PEPs page doesn't appear to reflect the change: http://www.python.org/dev/peps/ I checked to be sure it fixed it before I submitted the patch. That's why I asked about auto

[issue13487] inspect.getmodule fails when module imports change sys.modules

2011-11-26 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13487 ___ ___ Python-bugs-list

[issue12307] Inconsistent formatting of section titles in PEP 0

2011-11-28 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Thanks, Éric. That looks good. I'll keep that HTML title thing in mind. :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12307

[issue1877] unhelpful error when calling python dirname

2011-11-28 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1877 ___ ___ Python-bugs-list

[issue6816] Provide CPython command line functionality via runpy module

2011-11-28 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6816 ___ ___ Python-bugs-list

[issue11374] pkgutil.extend_path do not recognize py{c,o} file

2011-11-29 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11374 ___ ___ Python-bugs-list

[issue13533] Would like Py_Initialize to play friendly with host app

2011-12-05 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13533 ___ ___ Python-bugs-list

[issue11051] system calls per import

2011-12-05 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11051 ___ ___ Python-bugs-list

[issue2919] Merge profile/cProfile in 3.0

2011-12-09 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2919 ___ ___ Python-bugs-list

[issue13588] Change name of internal closure functions in importlib

2011-12-12 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13588 ___ ___ Python-bugs-list

[issue13585] Add contextlib.CleanupManager

2011-12-12 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Check out: http://code.activestate.com/recipes/ -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13585

[issue1559549] ImportError needs attributes for module and file name

2011-12-15 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Just following up on this ticket. Anyone have any objections to Brian's patch? Also, would 'fullname' be more appropriate than 'name', to be more in sync with that identifier in importlib

[issue2377] Replace __import__ w/ importlib.__import__

2011-12-15 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: AFAICT, #1559549 is the ImportError attribute ticket. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2377

[issue11957] re.sub confusion between count and flags args

2011-12-15 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11957 ___ ___ Python-bugs-list

[issue13592] repr(regex) doesn't include actual regex

2011-12-15 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13592 ___ ___ Python-bugs-list

[issue2134] Add new attribute to TokenInfo to report specific token IDs

2011-12-15 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2134 ___ ___ Python-bugs-list

[issue2292] Missing *-unpacking generalizations

2011-12-15 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2292 ___ ___ Python-bugs-list

[issue1559549] ImportError needs attributes for module and file name

2011-12-15 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: I'm guessing that more than just Python/import.c should be updated, and more than one spot in import.c. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1559549

[issue12082] Python/import.c still references fstat even with DONT_HAVE_FSTAT/!HAVE_FSTAT

2011-12-15 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12082 ___ ___ Python-bugs-list

[issue1785] inspect gets broken by some descriptors

2011-12-16 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1785 ___ ___ Python-bugs-list

[issue8098] PyImport_ImportModuleNoBlock() may solve problems but causes others.

2011-12-20 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8098 ___ ___ Python-bugs-list

[issue13645] test_import fails after test_coding

2011-12-21 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13645 ___ ___ Python-bugs-list

[issue13607] Move generator specific sections out of ceval.

2011-12-21 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13607 ___ ___ Python-bugs-list

[issue12857] Expose called function on frame object

2011-12-27 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: My response to a similar query: What it enables is the ability to introspect the *actual* function object belonging to the currently executing code, whether in the same execution frame or in a later one on the stack. We don't have

[issue13672] Add co_qualname attribute in code objects

2011-12-28 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: with f_func (see #12857) you would get that for free: frame.f_func.__qualname__ 'A.f1' -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13672

[issue13672] Add co_qualname attribute in code objects

2011-12-28 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: True. I wonder, though if perhaps a co_func (as a weak ref) or co_orig_func would be better, since co_qualname would be built from the original function anyway. Then you could call code.co_func.func_qualname. One sticky point

[issue13678] way to prevent accidental variable overriding

2011-12-29 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Interesting thought, the syntax seems unnecessary. Adding new syntax to the language is something that happens rarely and only with a _lot_ of consideration. As a slightly more verbose alternative, currently you can do this: def

[issue13562] Notes about module load path

2012-01-06 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13562 ___ ___ Python-bugs-list

[issue13728] Description of -m and -c cli options wrong?

2012-01-07 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: see http://docs.python.org/library/sys.html#sys.path As initialized upon program startup, the first item of this list, path[0], is the directory containing the script that was used to invoke the Python interpreter. If the script

[issue13703] Hash collision security issue

2012-01-16 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: The vulnerability is known since 2003 (Usenix 2003): read Denial of Service via Algorithmic Complexity Attacks by Scott A. Crosby and Dan S. Wallach. Crosby started a meaningful thread on python-dev at that time similar to the current

[issue6531] atexit_callfuncs() crashing within Py_Finalize() when using multiple interpreters.

2012-01-16 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6531 ___ ___ Python-bugs-list

[issue11948] Tutorial/Modules - small fix to better clarify the modules search path

2012-01-19 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: FYI: unless importlib took undue liberties (unlikely), frozen modules also precede path-based modules. See the implicit additions to sys.meta_path in Lib/importlib/_bootstrap.py. Whether or not to include a mention of frozen modules

[issue13912] ImportError using __import__ and relative level 1

2012-01-30 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: what value do you see for __package__ in pkgA? -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13912

[issue13912] ImportError using __import__ and relative level 1

2012-01-30 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: Jason: just a warning. importlib_backport is a relatively naive tool for generating the backport from the py3k source. It's also relatively fragile and at this point probably doesn't work with the default branch

[issue13912] ImportError using __import__ and relative level 1

2012-01-30 Thread Eric Snow
Eric Snow ericsnowcurren...@gmail.com added the comment: The problem is your level is off and the name is incomplete. master.pkgA.foo.py should have the following: __import__('pkgB.bar', master.pkgA.__dict__, level=2).bar or __import__('pkgB.bar', master.pkgA.__dict__, fromlist

[issue13405] Add DTrace probes

2012-02-02 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13405 ___ ___ Python-bugs-list

[issue16669] Docstrings for namedtuple

2012-12-13 Thread Eric Snow
Eric Snow added the comment: What is wrong with the following? class Point(namedtuple('Point', 'x y')): A 2-dimensional coordinate x - the abscissa y - the ordinate This seems more clear to me. namedtuple is in some ways a quick-and-dirty type, essentially a more true

[issue16669] Docstrings for namedtuple

2012-12-15 Thread Eric Snow
Eric Snow added the comment: +1, Terry -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16669 ___ ___ Python-bugs-list mailing list Unsubscribe

[issue16730] _fill_cache in _bootstrap.py crashes without directory execute permissions

2012-12-19 Thread Eric Snow
Eric Snow added the comment: Patch looks good to me. Are there any other exceptions that might be included here? -- nosy: +brett.cannon, eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16730

[issue16795] Patch: some changes to AST to make it more useful for static language analysis

2012-12-27 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16795 ___ ___ Python-bugs-list

[issue16894] Function attribute access doesn't invoke methods in dict subclasses

2013-01-09 Thread Eric Snow
Eric Snow added the comment: Looks like a case where the concrete dict API is ignoring subtype implementations. In your example the attribute access will be handled by a LOAD_ATTR which calls PyObject_GetAttr() (Python/ceval.c:2369). That ends up calling PyFunction_Type.tp_getattro

[issue16991] Add OrderedDict written in C

2013-01-17 Thread Eric Snow
New submission from Eric Snow: Here's an initial stab at writing OrderedDict in C. Though, the implementation is not heavily optimized and isn't super subclass-friendly, my hope is that it's relatively close to the final version. I'm getting this up now to get some eyes on it. The spot

[issue16991] Add OrderedDict written in C

2013-01-19 Thread Eric Snow
Eric Snow added the comment: @Benjamin: Yeah, I've fixed that. @Ezio: Good point. I've touched that up. Once I have cleared up reference counting issues I'll put up a new patch. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue16803] Make test_importlib run tests under both _frozen_importlib and importlib._bootstrap

2013-01-23 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16803 ___ ___ Python-bugs-list

[issue16651] Find out what stdlib modules lack a pure Python implementation

2013-01-25 Thread Eric Snow
Eric Snow added the comment: Also missing a pure-Python implementation: collections.defaultdict (relatively trivial) collections.deque In the spirit of what Brett said, I found that PyPy has an implementation already: https://bitbucket.org/pypy/pypy/src/default/lib_pypy/_collections.py

[issue1674555] sys.path in tests contains system directories

2013-01-25 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1674555 ___ ___ Python-bugs

[issue16991] Add OrderedDict written in C

2013-01-25 Thread Eric Snow
Eric Snow added the comment: Here's a cleanup of test.test_collections that helps keep the subsequent patch (still forthcoming) cleaner. -- Added file: http://bugs.python.org/file28839/cleanup-test-collections.diff ___ Python tracker rep

[issue17037] Add conforms_to_pep399() to test.support

2013-01-25 Thread Eric Snow
New submission from Eric Snow: Related to issue #16817 and to my efforts on a C OrderedDict, I think it would be nice to have a class decorator that handles most of the PEP 399 requirements for you. The attached patch adds such a decorator to test.support. -- assignee: eric.snow

[issue16817] test___all__ affects other tests by doing too much importing

2013-01-25 Thread Eric Snow
Eric Snow added the comment: So the current solution is to temporarily put the relevant module in place in sys.modules, right? That seems to be the solution that Stefan recommended and used in the decimal module. Sounds good to me. I'm hitting this while doing the PEP 399 two-step

[issue17037] Add conforms_to_pep399() to test.support

2013-01-25 Thread Eric Snow
Eric Snow added the comment: One lingering doubt I have is about how I throw the two new test case classes into the globals. They're already getting bound, as a pair, to the original test class's name... -- ___ Python tracker rep

[issue17037] Add conforms_to_pep399() to test.support

2013-01-25 Thread Eric Snow
Eric Snow added the comment: One step I left out is handling the whole pickle/copyreg case outlined by #16817. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17037

[issue14715] test.support.DirsOnSysPath should be replaced by importlib.test.util.import_state

2013-01-25 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14715 ___ ___ Python-bugs-list

[issue16737] Different behaviours in script run directly and via runpy.run_module

2013-01-26 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16737 ___ ___ Python-bugs-list

[issue16748] Make CPython test package discoverable

2013-01-26 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue16748 ___ ___ Python-bugs-list

[issue11995] test_pydoc loads all Python modules

2013-01-26 Thread Eric Snow
Changes by Eric Snow ericsnowcurren...@gmail.com: -- nosy: +eric.snow ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11995 ___ ___ Python-bugs-list

[issue17037] Add conforms_to_pep399() to test.support

2013-01-26 Thread Eric Snow
Eric Snow added the comment: The decorator also mitigates the problem described in issue #16835. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue17037

  1   2   3   4   5   6   7   8   9   10   >