Skip to content
Better HN
Top
Best
Ask
Show
New
Jobs
Search
⌘K
Ask HN: Is function patching in Python acceptable for a library to do?
3 points
roh26it
1y ago
2 comments
Save
Share
2 comments
2 comments · 1 top-level
top
newest
oldest
patrakov
1y ago
· 1 in thread
Yes, if this is documented and not done by default. Example:
https://www.gevent.org/api/gevent.monkey.html
brodouevencode
1y ago
Implementing like gevent did is also preferable, where you can patch some or all as arguments to the patch call.
j
/
k
navigate · click thread line to collapse