[Biopython-dev] Further PEP8 Cleanup

Peter Cock p.j.a.cock at googlemail.com
Wed Dec 5 14:16:43 UTC 2012


On Mon, Dec 3, 2012 at 5:02 PM, Christian Brueffer
<christian at brueffer.de> wrote:
>> As you point out, the "repo churn" from fixing minor things
>> like spaces around operators does have a cost in making
>> merges a little harder. Things like the exception style updates
>> which you've already fixed (seems I missed some) are more
>> urgent for Python 3 support, so worth doing anyway.
>>
>
> On the other hand, it's basically a one-time cost.  However I
> want to fix the lowest-hanging fruit (read: the ones with the
> lowest counts ;-) first.

The shear number of files touched in these PEP8 fixes would
probably deserve to be called "repository churn" now - wow!

Although we have good test coverage, it isn't complete (anyone
fancy trying some test coverage measuring tools like figleaf?)
so there is a small but real risk we've accidentally broken
something. I'm wondering if therefore a 'beta' release would
be prudent, of if I am just worrying about things too much?

>> You've got us a lot closer to PEP8 compliance - do you think
>> subject to a short white list of known cases (like module
>> names) where we don't follow PEP8 we could aim to run a
>> a pep8 tool automatically (e.g. as a unit test, or even a commit
>> hook)? That is quite appealing as a way to spot any new code
>> which breaks the style guidelines...
>
> Having a commit hook would be ideal (maybe with a possibility to
> override).  This would be especially useful against the introduction of
> gratuitous whitespace.  With some editors/IDEs you don't even notice it.

Would you be interested in looking into how to set that up?
Presumably a client-side git hook would be best, but we'd
need to explore cross platform issues (e.g. developing and
testing on Windows) and making sure it allowed an override
on demand (where the developer wants/needs to ignore a
style warning).

Thanks,

Peter



More information about the Biopython-dev mailing list