← Back to team overview

openerp-community team mailing list archive

Re: Coding Guidlines - long lines

 

Thanks for the explanation Guewen. I think the debate is over with that ;)

http://www.python.org/dev/peps/pep-0008/#maximum-line-length

PEP8 is the reference, it's not about people's preference I fear..


On Tue, Nov 26, 2013 at 9:00 AM, Guewen Baconnier <
guewen.baconnier@xxxxxxxxxxxxxx> wrote:

> On 11/25/2013 10:30 PM, Markus Schneider wrote:
>
>> hello,
>>
>> [background]i start this discussion, because i want to submit my code,
>> but fulfil even 79 rule, our merge request are still open, but this is a
>> other problem[/backgound]
>>
>> in my opinion the "i prefer" discussion has not outcome. I guess we need
>> a good example where 79 char rule is implemented and the module is
>> complex. I look in the new magento-connector and there 7500 times
>> breaking this rule over all modules you need to use.
>>
>> So if the big contributors like Camp2Camp will use this rule strict, the
>> rest of the community will follow, i think.
>>
>> If the big one ignoring it and you say to the small one (like us) use
>> it, you will loss us.
>>
>> [ironic]i name my variable "absrl" instad of
>> account_bank_statement_reconcile_line, this saves me a lot of chars, but
>> the code will be worst[/ironic]
>>
>
>
> Hello,
>
> I didn't want to comment on that thread, but now that I have been
> summoned, so... well, 7500 too long lines on the Magento Connector is
> stupid.
>
> I do respect and promote the 79 chars limit and as far as I know all my
> colleagues at Camptocamp too.
>
> 'pep8' counts 43 too long lines in the Connector module (~3000 lines) and
> 109 in the Magento Connector module (~4200 lines).  A lot of them are at 80
> chars or barely more.  You can't consider the other dependencies whose code
> has grown up since at least 6.1.  Of course, if you add the test data which
> is recorded from the Magento API, the number increases up to 7500 errors...
> data which would be a joke to pep8ify.
>
> So if you search an example using the 79 chars rule, just look, with your
> eyes, and not with pyflakes/pep8 tools, in the connector modules (and avoid
> the test data files).
>
> I also have found that respecting the coding style leads people to do the
> same, and I think that, just like Sébastien Beau said on this thread, they
> end up to prefer it.
>
> On a point I think you are right: there is no place for a "I prefer"
> debate.  If we, as a team, can't agree on the 99 chars limit, pep8 rule is:
> 79 chars.
>
> Is there a magic word to close this never-ending debate?
>
> --
> Guewen Baconnier
> Business Solutions Software Developer
>
> Camptocamp SA
> PSE A, CH-1015 Lausanne
> Phone: +41 21 619 10 39
> Office: +41 21 619 10 10
> http://www.camptocamp.com/
>
>
> _______________________________________________
> Mailing list: https://launchpad.net/~openerp-community
> Post to     : openerp-community@xxxxxxxxxxxxxxxxxxx
> Unsubscribe : https://launchpad.net/~openerp-community
> More help   : https://help.launchpad.net/ListHelp
>



-- 


*camptocamp*
INNOVATIVE SOLUTIONS
BY OPEN SOURCE EXPERTS

*Joël Grand-Guillaume*
Division Manager
Business Solutions

+41 21 619 10 28
www.camptocamp.com

References