In multimethod there is this code, and I'm wondering why it doesn't take into account the kwargs?
def __call__(self, *args, **kwargs):
"""Resolve and dispatch to best method."""
return self[tuple(map(self.get_type, args))](*args, **kwargs)
Is it because it's unknown what is the right order for the kwargs? Also in the get_types method, the keyword_only arguments will not be considered as well. And arguments with default values are not considered as well...
So, I'm just wondering why this design decision was made?
Because in my current usecase I have a need for this and was wondering about the logic behind its current implementation. Otherwise I could take a shot at 'fixing' the issue as I see it?
Hi,
In multimethod there is this code, and I'm wondering why it doesn't take into account the kwargs?
Is it because it's unknown what is the right order for the kwargs? Also in the
get_types
method, the keyword_only arguments will not be considered as well. And arguments with default values are not considered as well... So, I'm just wondering why this design decision was made?Because in my current usecase I have a need for this and was wondering about the logic behind its current implementation. Otherwise I could take a shot at 'fixing' the issue as I see it?
Thanks