[issue2439] Patch to add a get_data function to pkgutil

Paul Moore report at bugs.python.org
Fri Mar 21 15:15:08 CET 2008


Paul Moore <p.f.moore at gmail.com> added the comment:

It has to be a valid loader, as I see no reason to support loaders that
aren't valid. In any case, I did try incrementing a counter and it
doesn't demonstrate the problem. If you try the currently attached
patch, you should see that. (I assume you've tried or at least read the
current patch - but the fact that you're suggesting the approach I have
implemented makes me wonder. I did re-upload the patch after you
reported the issue - msg 64225 - maybe you didn't notice this, as I
deleted the old patch?) If you do see what I mean, please tell me where
my code is wrong. I don't want to add a fix without a test showing why
the current behaviour is wrong. The test_alreadyloaded test is intended
to do that, but the current pkgutil code doesn't fail the test - so
either the test is wrong (and I'd appreciate help fixing the test) or
the "problem" isn't real, and I can leave the code as is.

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue2439>
__________________________________


More information about the Python-bugs-list mailing list