So in python's docutils package there is a class (Image) that has a method (align). As I understood it methods take self as a first argument unless they are decorated as @classmethod or @staticmethod, however align doesn't. The relevant code is copied below (full code here).
class Image(Directive): def align(argument): # This is not callable as self.align. We cannot make it a # staticmethod because we're saving an unbound method in # option_spec below. return directives.choice(argument, Image.align_values) I'm using this code as a base for my own purposes, and I have tried both giving align a self argument and turning it into a static method (after changing the name so as not to conflict with self.align), but got errors with either approach. What is going on?