Skip to content

Why not use decorators? #135

Answered by tiangolo
FeeeeK asked this question in Questions
Discussion options

You must be logged in to vote

It's because decorating a function with asyncify would make it only awaitable, it wouldn't be callable from blocking code, while the logic and code underneath are purely sync. And documenting it could encourage it, while it's probably not ideal, so I prefer not to document it.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by tiangolo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
2 participants