Author corona10
Recipients corona10, eric.snow, koubaa, terry.reedy, vstinner
Date 2020-09-10.08:58:37
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
One of my opinions is that

Since module object supports detecting error during Py_mod_exec,
The only thing we have to do is return -1 when the module has already existed.

we should define new exception type and don't have to define new slots.
The pros of this method is that we don't have to modify module object and no needs to write the new PEP

but the cons of this method is that we should promise the standard exception when try to create multiple instances which is not allowed.


On the other side, defining a Py_mod_exec_once that supports execution for just once can be a way.
Although the usage is little, it will be fine because the use case will exist.

Please point out what I missed :)
Date User Action Args
2020-09-10 08:58:38corona10setrecipients: + corona10, terry.reedy, vstinner, eric.snow, koubaa
2020-09-10 08:58:38corona10setmessageid: <>
2020-09-10 08:58:38corona10linkissue40600 messages
2020-09-10 08:58:37corona10create