Python and PEP8 core library

I was trying to understand why Python is considered a beautiful language. I was aimed at the beauty of PEP 8 ... and it was weird. In fact, he says that you can use any convention you need, just be consistent ... and suddenly I discovered some strange things in the main library:

request()
getresponse()
set_debuglevel()
endheaders()
http://docs.python.org/py3k/library/http.client.html

The following functions are new in Python 3.1. What part of the PEP 8 agreement is used here?

popitem()
move_to_end()
http://docs.python.org/py3k/library/collections.html

So my question is: is PEP 8 used in the main library or not? Why is this so? Is there the same situation as in PHP where I can’t just remember the name of the function, because all the ways of writing the name are possible?

Why is PEP 8 not used in the main library even for new features?

+5
3

PEP8:

: , -      . , .      , . !

, , PEP8; , , CamelCase.

+4

PEP 8 , :

  • - API (, )
  • ( ).

, :

  • popitem - dict. API, , (.. ).

  • move_to_end . , , PEP 8 , movetoend ( , toe - , nd)

  • set_debuglevel ( set_tunnel), , API HTTPConnection. set_debuglevel setdebuglevel ( , debuglevel HTTPConnection, ), set_tunnel .

  • set_tunnel - , , , . "t" s settunnel .

Python, ( -Javaify threading Python 2 Python 3, , "" API, ).

+10

Python , , . , , , Python , Java, Win32. ( ) , , , .

, , , .

+2

All Articles