In python, super() is always called first in a method. Are there situations where it should be called later?

Sometimes you need to validate the arguments before calling super():

class UpperBase(Base):
    def __init__(self, name):
        if not name_valid(name):
            raise ValueError()
        super(UpperBase, self).__init__(name)

I don’t see why this wouldn’t be pythonic, because it’s the easiest way to do it and it’s straightforward.
Also, read @JHSaunders’ comment, he makes a good point.

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)