Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
![](/static/devrant/img/pipeless-devrant-banner-white.png)
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
len means length, str means string.
idk man seems simple to me
But yes, the inconsistent naming is also annoying to me. It should always be snake_case.
Also, fuck Python 2 -
Pythons are adorable. They function as my little cuddle noodles. I really would like another ball python. ❤️
Oh, that python. Yeah it's alright. -
I hate it from the bottom of my heart. I don't know why you even would use it. What's it's advantage over js, java, c or anything else?
-
I love everything about Python except for the syntactical whitespace.
I use it a lot at work to automate or glue together a bunch of shit. Might deploy a web2py small application if I feel cute enough because shit like the admin interface and the alreadyhereforyouidiotstouse interface is a time saver.
But naming convetions, afterthought feel of oop, and the horrible use of __penis__ definitely annoys me. And I can't for the life of me remember to self on class methods, even after years of use.
I am meh about Python, but know it so well that I make due with my meh attitude towards it. -
Py3 is _mostly_ compatible with Py2, except for some changes that couldn't be made without BC breaks - that's why it's called Python 3 rather than Python 2.8. The transition was long and painful, many people refused to adopt Py3 for various reasons. But now Py2 is officially dead, so things should be improving.
-
len() and str() doesn't bother me much, but syntax of for loop with indices does.
I prefer for(i=0; i<n; i++) style rather than enumerate(). Since python doesn't support ++ I'm ready to replace ++ with +=
And yes consistency of snake_case should be there. IT HAS TO BE FOLLOWED!
Large codebases in python sucks if they are inconsistent and even with consistency it takes time to understand.
If dunder methods are your weakness such as __call__ you will have hard time getting your head around OOP based codebases. -
Oh another rant about naming conventions. Let's see who's right this time 😂
It would be nice if there were a global way of doing it, but there isn't. Different strokes for different folks. As long as it doesn't give you a stroke in the process. -
As far as I understand those books (Clean Code, Design Patterns) are aimed to be used with OOP languages.
Python is not object oriented. It is rather a protocol based lang (somewhat similar to functional programming languages like C).
Protocol based because of those __internal_function__() functions like __len__(), __str__() and so on.
I also personally often struggle to name things in python. As far as i gather you use snake_case and ditch getters/setters in favor of properties.
Python is often described as "glue" since thanks to a lot of system library wrappers, you can often interact better with OS libs than in most other langs.
Also python is one of the langs that got popular not because it was hyped, has a lot of R&D invested, was named after another popular language (looking at you, JS!) or was a recommended and tightly integrated language for a given platform (e.g. C#).
Python got steadily better. PEP by PEP (Python Enhancement Proposal).
(Java also adopted PEPs as JEPs.) -
@pxeger if you created an account just for this single comment... Well done man, welcome here
Related Rants
Anybody loves python? I don't know why, but the more I use python, the more I seem to hate it. Specially the poor naming of the functions are just horrible! specially when you've been following the #CleanCodePrinciple strictly.
Let me give some example:
What does even "len" or "str" mean normally? is it a variable or a function? can anybody imagine?
where as in Java or JavaScript it is array.length and anyValue.toString()
anybody can understand what these things are, whether a variable or a function.
in python some functions are like "dothisorthat" and some are "do_this_or_that" some are "doThisOrThat". I mean, why can't you just follow an unified rule?
and there's this fragmentation between python 2 and 3! whether in stackoverflow or in youtube/udemy, a lot of them used python 2 and some uses python 3. I mean, can't they have some BackworkSupports?
rant
python