Author steve.dower
Recipients gousaiyang, steve.dower
Date 2021-04-07.00:44:13
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1617756254.24.0.99569959705.issue43756@roundup.psfhosted.org>
In-reply-to
Content
Solution 1 is definitely out, as PyArg_ParseTuple is a very valid way to implement hooks but won't handle longer tuples.

For Solution 2, we already have some events that use a slash to indicate "extra" information, so depending on context I'd either do "glob.glob/2" or add both "glob.glob/root_dir" and "glob.glob/dir_fd" events.

I suspect in this case, the "glob.glob/2" name is better, because all the data really has to come together. Sending those values through separately might make more sense if there's some other linkable id (such as for socket events).

Nobody should handle hooks that they don't expect with anything other than *args (and even then they should be careful, as hooks may pass through MB or GB of data, so logging or printing them directly may be a bad idea).
History
Date User Action Args
2021-04-07 00:44:14steve.dowersetrecipients: + steve.dower, gousaiyang
2021-04-07 00:44:14steve.dowersetmessageid: <1617756254.24.0.99569959705.issue43756@roundup.psfhosted.org>
2021-04-07 00:44:14steve.dowerlinkissue43756 messages
2021-04-07 00:44:13steve.dowercreate