mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-02-21 14:24:09 +01:00
Use check_output
instead of run
This is shorter and more readable Suggested-By: @cdecker
This commit is contained in:
parent
03e7a03a09
commit
77989b106f
1 changed files with 2 additions and 4 deletions
|
@ -612,10 +612,8 @@ class LightningD(TailableProc):
|
|||
self.opts = LIGHTNINGD_CONFIG.copy()
|
||||
|
||||
# Query the version of the cln-binary
|
||||
cln_version_proc = subprocess.run(
|
||||
[self.executable, "--version"],
|
||||
stdout=subprocess.PIPE)
|
||||
self.cln_version = NodeVersion(cln_version_proc.stdout.decode('ascii').strip())
|
||||
cln_version_proc = subprocess.check_output([self.executable, "--version"])
|
||||
self.cln_version = NodeVersion(cln_version_proc.decode('ascii').strip())
|
||||
|
||||
opts = {
|
||||
'lightning-dir': lightning_dir,
|
||||
|
|
Loading…
Add table
Reference in a new issue