[python-committers] do we still believe explicit relative imports are bad as PEP 8 claims?
Tarek Ziadé
ziade.tarek at gmail.com
Sat Feb 19 00:20:24 CET 2011
On Fri, Feb 18, 2011 at 10:35 PM, M.-A. Lemburg <mal at egenix.com> wrote:
> Brett Cannon wrote:
>> It says they are "highly discouraged" because "absolute imports are
>> more portable and usually more readable", but now that people have had
>> a chance to use explicit relative imports, do people still believe
>> this? I mean if we truly believed this then why did we add the syntax?
>> I know I have used it and love it, let alone that I don't buy the
>> portability argument.
>
> Let's put it this way: I think that PEP 8 gets way too much
> attention in Python land.
>
> It describes one way of doing things, but is not a bible or
> strict style guide (and even says that)
Yeah but it exists. And it very useful to have, I'd say.
1 - when you start Python, it gives you a sense of how a "beautiful"
Python code should look.
2 - for any new project, I personally recommend strict PEP 8 instead
of inventing another convention.
3 - It's documented, widely adopted, and we have existing tools to
check for compliancy out there.
Cheers
Tarek
--
Tarek Ziadé | http://ziade.org
More information about the python-committers
mailing list