diff --git a/sphinx/builders/latex/__init__.py b/sphinx/builders/latex/__init__.py index 23ef8e76b..f48a687f7 100644 --- a/sphinx/builders/latex/__init__.py +++ b/sphinx/builders/latex/__init__.py @@ -138,7 +138,7 @@ class LaTeXBuilder(Builder): def get_target_uri(self, docname: str, typ: str = None) -> str: if docname not in self.docnames: - raise NoUri + raise NoUri(docname) else: return '%' + docname