From b7bccfeee314b7380434f6f762c82f35188ddb47 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sybren=20A=2E=20St=C3=BCvel?= Date: Wed, 24 May 2017 15:47:05 +0200 Subject: [PATCH] Annotate sidebar_links(project) param + return type --- pillar/extension.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/pillar/extension.py b/pillar/extension.py index bb7a59b0..928948b2 100644 --- a/pillar/extension.py +++ b/pillar/extension.py @@ -17,6 +17,8 @@ can then be registered to the application at app creation time: import abc +import pillarsdk + class PillarExtension(object, metaclass=abc.ABCMeta): @property @@ -94,7 +96,7 @@ class PillarExtension(object, metaclass=abc.ABCMeta): def setup_app(self, app): """Called during app startup, after all extensions have loaded.""" - def sidebar_links(self, project): + def sidebar_links(self, project: pillarsdk.Project) -> str: """Returns the sidebar link(s) for the given projects. :returns: HTML as a string for the sidebar.