pytest: fix use of deprecated `getroute` in tests/test_misc.py::test_graceful_htlc
What changed, and why it matters
This is a routine test-only fix. A single pytest test case was still calling an old, deprecated RPC command named 'getroute'. The patch replaces it with the current helper method 'single_route'. There is no change to production code, no security bug, and no vulnerability.
No security action needed. Treat as normal maintenance/test hygiene.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The commit updates tests/test_misc.py::test_graceful_htlc to stop using the deprecated getroute RPC and instead use l1.single_route(…). The diff is one line in a test file. No node logic, RPC implementation, or protocol behavior is modified.
Changed components
tests/test_misc.pyInspect captured patch +1 / −1
diff --git a/tests/test_misc.py b/tests/test_misc.py
index 0d0bd201..b10a83b2 100644
--- a/tests/test_misc.py
+++ b/tests/test_misc.py
@@ -4337,7 +4337,7 @@ def test_graceful_htlc(node_factory, executor):
{'plugin': os.path.join(os.getcwd(), 'tests/plugins/hold_invoice.py')}])
inv = l3.rpc.invoice(10000, 'hold', 'hold invoice')
- route = l1.rpc.getroute(l3.info['id'], 10000, 1)['route']
+ route = l1.single_route(l3.info['id'], 10000)
l1.rpc.sendpay(route, inv['payment_hash'], payment_secret=inv['payment_secret'])
wait_for(lambda: len(only_one(l3.rpc.listpeerchannels()['channels'])['htlcs']) == 1)
Why this scored 15/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.