Brett Cannon <br...@python.org> added the comment:

> Mostly looking for something that says how `create_module` should / shouldn't 
> be implemented

Basically you only need to provide the method if you want to use a custom 
object for the module itself. So as long as the object can quack like a module 
object you should be fine.

> (and why `return None` is necessary)

The "return None for default semantics" is there for two reasons (if I remember 
correctly). One, it makes it very easy to implement the default semantics. :) 
Two, it sends a very clear signal that nothing out of the ordinary is going on 
and so you can assume nothing special is expected (which is why LazyLoader 
requires this since it mucks with the object directly in a very specific way).

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue23014>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to