From 8796f6c6b0305ee19ba176769b2ef50107b938a6 Mon Sep 17 00:00:00 2001 From: Michael Schmoock Date: Sun, 13 Dec 2020 00:52:04 +0100 Subject: [PATCH] monitor: fix flake8 nits --- monitor/monitor.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/monitor/monitor.py b/monitor/monitor.py index 24c2efb..27548a1 100755 --- a/monitor/monitor.py +++ b/monitor/monitor.py @@ -4,6 +4,7 @@ This is a quick hack and adapted plugin from the summary.py plugin (orinigally w This one is adapted by Rene Pickhardt and aims to help you identify inactive channels quickly """ +from packaging import version import pyln.client import json @@ -11,11 +12,12 @@ plugin = pyln.client.Plugin() # __version__ was introduced in 0.0.7.1, with utf8 passthrough support. try: - if version.parse(lightning.__version__) >= version.parse("0.0.7.1"): + if version.parse(lightning.__version__) >= version.parse("0.0.7.1"): # noqa F821 have_utf8 = True except Exception: pass + @plugin.method("monitor") def monitor(plugin): """Monitors channels of this node.""" @@ -65,4 +67,5 @@ def monitor(plugin): def init(options, configuration, plugin): plugin.log("Plugin monitor.py initialized") + plugin.run()