[Grok-dev] martian scan "bug" (feature?)
chrism at plope.com
Thu Nov 20 09:58:34 EST 2008
Lennart Regebro wrote:
> On Wed, Nov 19, 2008 at 14:53, Chris McDonough <chrism at plope.com> wrote:
>> When martian scans packages (via the ModuleGrokker), eventually it winds up
>> scanning modules that are defined via .pyc and .pyo file representations that do
>> not have a corresponding .py source file. This, at least in my configuration,
>> leads to errors because these are typically modules left over after, e.g. a
>> module rename, where the "old" .pyc file sticks around even though its source
>> file has changed names and has new content.
> Well. this is how python works. You can even distribute only pyc
> files, if you want.
Yup, but it's not the usual case. In fact, I personally don't want to
contribute code that makes it by-default-easy to use this distribution model.
That said, the patch I sent over lets folks *not* ignore .pyc files (they just
have to pass in ignore_nonsource=False).
> (We did that with EasyPyblisher for a while in fact).
> I don't think Grok should try to circumvent this.
The difference here is that Martian imports everything it finds, whereas in
normal operations a "stray" pyc might exist but would never be imported or
More information about the Grok-dev