A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2015-December/142625.html below:

[Python-Dev] PEP 257 and __init__

[Python-Dev] PEP 257 and __init__ [Python-Dev] PEP 257 and __init__Ben Finney ben+python at benfinney.id.au
Tue Dec 29 16:53:37 EST 2015
Facundo Batista <facundobatista at gmail.com> writes:

> Note that I'm ok to include a docstring when the actual behaviour
> would deviate from the expected one as per Reference Docs. My point is
> to not make it mandatory.

I disagree with the exception you're making for ‘__init__’. The
parameters to that function (and how the function behaves in response)
should be documented in the docstring, just as for any other function.

> Yeap, but pep257 (the tool [0]) complains for __init__, and wanted to
> know how serious was it.

Omitting a docstring violates PEP 257, regardless which function we're
talking about. So the tool is correct to complain.

-- 
 \         “If we don't believe in freedom of expression for people we |
  `\           despise, we don't believe in it at all.” —Noam Chomsky, |
_o__)                                                       1992-11-25 |
Ben Finney

More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4