Files
palladum-lightning/tests/test_reckless.py
Rusty Russell f5fe10c4d5 pytest: fix flake in reckless install timeout.
Don't test installing a plugin under valgrind.  There's no way to
increase reckless' (completely reasonable) 15 seconds timeout, and that
can happen under valgrind & CI:

```
 def test_reckless_uv_install(node_factory):
        node = get_reckless_node(node_factory)
        node.start()
        r = reckless([f"--network={NETWORK}", "-v", "install", "testpluguv"],
                     dir=node.lightning_dir)
>       assert r.returncode == 0
E       assert 1 == 0
E        +  where 1 = self.returncode, self.stdout, self.stderr.returncode

tests/test_reckless.py:359: AssertionError
...
***RECKLESS STDERR***
config file not found: /tmp/ltests-tui1vmrg/test_reckless_uv_install_1/lightning-1/regtest/config
press [Y] to create one now.
config file not found: /tmp/ltests-tui1vmrg/test_reckless_uv_install_1/lightning-1/reckless/regtest-reckless.conf
config file not found: /tmp/ltests-tui1vmrg/test_reckless_uv_install_1/lightning-1/reckless/.sources
Traceback (most recent call last):
  File "/home/runner/work/lightning/lightning/tools/reckless", line 2091, in <module>
    log.add_result(args.func(target))
  File "/home/runner/work/lightning/lightning/tools/reckless", line 1524, in install
    return _enable_installed(installed, plugin_name)
  File "/home/runner/work/lightning/lightning/tools/reckless", line 1476, in _enable_installed
    if enable(installed.name):
  File "/home/runner/work/lightning/lightning/tools/reckless", line 1647, in enable
    lightning_cli('plugin', 'start', path)
  File "/home/runner/work/lightning/lightning/tools/reckless", line 1613, in lightning_cli
    clncli = run(cmd, stdout=PIPE, stderr=PIPE, check=False, timeout=timeout)
  File "/opt/hostedtoolcache/Python/3.10.18/x64/lib/python3.10/subprocess.py", line 505, in run
    stdout, stderr = process.communicate(input, timeout=timeout)
  File "/opt/hostedtoolcache/Python/3.10.18/x64/lib/python3.10/subprocess.py", line 1154, in communicate
    stdout, stderr = self._communicate(input, endtime, timeout)
  File "/opt/hostedtoolcache/Python/3.10.18/x64/lib/python3.10/subprocess.py", line 2022, in _communicate
    self._check_timeout(endtime, orig_timeout, stdout, stderr)
  File "/opt/hostedtoolcache/Python/3.10.18/x64/lib/python3.10/subprocess.py", line 1198, in _check_timeout
    raise TimeoutExpired(
subprocess.TimeoutExpired: Command '['/home/runner/work/lightning/lightning/cli/lightning-cli', '--network=regtest', '--lightning-dir=/tmp/ltests-tui1vmrg/test_reckless_uv_install_1/lightning-1', 'plugin', 'start', '/tmp/ltests-tui1vmrg/test_reckless_uv_install_1/lightning-1/reckless/testpluguv/testpluguv.py']' timed out after 15 seconds
```

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2025-09-30 11:37:31 +09:30

15 KiB