Index: domains/python.py =================================================================== --- domains/python.py (revision 89001) +++ domains/python.py (working copy) @@ -643,6 +643,12 @@ matches = self.find_obj(env, modname, clsname, target, type, searchmode) if not matches: + msg = ':%s:`%s` target not found' % (type, target) + if clsname is not None: + msg += ' in class %s' % (clsname,) + if modname is not None: + msg += ' in module %s' % (modname,) + env.warn(fromdocname, msg, node.line) return None elif len(matches) > 1: env.warn(fromdocname,