-
Notifications
You must be signed in to change notification settings - Fork 9
Description
I would like to be able to specify the module name of a properties.Instance property. Sometimes these class reside in a module that does not specifically have documentation of it. This can happen fairly often in a code. For example, see the discretize documentation for the discretize.base.BaseMesh (http://discretize.simpeg.xyz/en/master/api/generated/discretize.base.BaseMesh.html) where the actual module where it is defined is in the discretize.base.base_mesh.BaseMesh (https://github.com/simpeg/discretize/blob/e353fb53ec254aa2a18733679da3fddae71ddbb7/discretize/base/base_mesh.py#L14) However we don't necessarily want that module exposed to the documentation, but would still like to generate automatic links to it from other packages.
The current Instance class will generate a documentation target for the property using instance_class.__module__.
properties/properties/base/instance.py
Line 183 in 85dccbb
| def sphinx_class(self): |
As far as I know there would be no way to programmatically get where the item was imported through, so I propose adding an optional argument to the properties.Instance class that would hold this module_name.