osdir.com


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

transform a "normal" decorator in one for async functions


On 2018-09-18 16:20, vito.detullio at gmail.com wrote:
> but I cannot rewrite this library.

Perhaps not, but surely you can write your own decorator that does
whatever this library's decorator does for async functions? Presumably
you have the code...

> is there a way to "convert" a "normal" decorator in one that can handle async functions?

In general? No.