autoclean: new interface

In preparation for more things being autocleaned.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
Rusty Russell
2022-09-19 10:19:52 +09:30
committed by Christian Decker
parent 41a52929f7
commit bd76a196f5
5 changed files with 252 additions and 31 deletions

View File

@@ -531,6 +531,15 @@ class LightningRpc(UnixDomainSocketRpc):
}
return self.call("autocleaninvoice", payload)
def autoclean_status(self, subsystem=None):
"""
Print status of autocleaning (optionally, just for {subsystem}).
"""
payload = {
"subsystem": subsystem,
}
return self.call("autoclean-status", payload)
def check(self, command_to_check, **kwargs):
"""
Checks if a command is valid without running it.