Best practices for using super()
Peter Slížik
peter.slizik at gmail.com
Tue Jul 4 08:20:08 EDT 2023
As a follow-up to my yesterday's question - are there any recommendations
on the usage of super()?
It's clear that super() can be used to invoke parent's:
- instance methods
- static methods
- constants ("static" attributes in the parent class, e.g. super().NUMBER).
This all works, but are there situations in which calling them explicitly
using a parent class name is preferred?
Best regards,
Peter
More information about the Python-list
mailing list