Message416024
It is Django I would worry about and look at closely as they do stuff with decorators on instance methods that uses partials.
https://github.com/django/django/blob/7119f40c9881666b6f9b5cf7df09ee1d21cc8344/django/utils/decorators.py#L43
```
def _wrapper(self, *args, **kwargs):
# bound_method has the signature that 'decorator' expects i.e. no
# 'self' argument, but it's a closure over self so it can call
# 'func'. Also, wrap method.__get__() in a function because new
# attributes can't be set on bound method objects, only on functions.
bound_method = wraps(method)(partial(method.__get__(self, type(self))))
for dec in decorators:
bound_method = dec(bound_method)
return bound_method(*args, **kwargs)
``` |
|
Date |
User |
Action |
Args |
2022-03-25 23:18:35 | grahamd | set | recipients:
+ grahamd, ping, ncoghlan, larry, yselivanov, BTaskaya, ofey404 |
2022-03-25 23:18:35 | grahamd | set | messageid: <1648250315.24.0.644426366704.issue46761@roundup.psfhosted.org> |
2022-03-25 23:18:35 | grahamd | link | issue46761 messages |
2022-03-25 23:18:35 | grahamd | create | |
|