I have a class like this.
from flask.views import MethodView
class FirstClass(MethodView):
I have another class like this.
class SecondClass(FirstClass):
def post(self):
logging.info(self.request.body)
I was expecting that the SecondClass would inherit MethodView Class. But it is not inheriting it. The MethodView will call the "post" def when there is a POST call, but it is not executing the "post" function. What should I do to have the SecondClass inherit MethodView class?
I was hoping to avoid (due to complexity in code)
class SecondClass(FirstClass, MethodView):
def post(self):
logging.info(self.request.body)
When I do the above the MethodView kicks in to execute the "post" function when there is a POST call.
issubclass(SecondClass, MethodView) == True, no?