Skip to content

askrene: deprecate auto.no_mpp_support layer, use maxparts=1 instead#8998

Closed
ThomsenDrake wants to merge 2 commits into
ElementsProject:masterfrom
ThomsenDrake:deprecate-auto-no-mpp
Closed

askrene: deprecate auto.no_mpp_support layer, use maxparts=1 instead#8998
ThomsenDrake wants to merge 2 commits into
ElementsProject:masterfrom
ThomsenDrake:deprecate-auto-no-mpp

Conversation

@ThomsenDrake

Copy link
Copy Markdown

The auto.no_mpp_support layer was used to force single-path payments for destinations that don't support MPP. Since maxparts=1 already switches to the single-path algorithm (line ~616 in askrene.c), the layer is redundant.

Changes

plugins/askrene/askrene.c (net -44 lines):

  • Remove remove_small_channel_layer() function entirely
  • Remove auto.no_mpp_support from layer name validation
  • Remove the auto.no_mpp_support branch from layer creation/handling
  • Remove the separate algorithm override block (maxparts=1 already handles this)

plugins/xpay/xpay.c (+3/-2):

  • When disable_mpp is set (invoice doesn't offer OPT_BASIC_MPP), send maxparts=1 to getroutes instead of adding the auto.no_mpp_support layer

tests/test_askrene.py (6 test calls updated):

  • Replace layers=["auto.no_mpp_support"] with maxparts=1 in test_getroutes_single_path, test_excessive_fee_cost, and test_impossible_payment
  • Add maxparts parameter support to check_getroute_paths() helper

doc/schemas/getroutes.json:

  • Update description from "four automatic layers" to "three automatic layers"
  • Document that maxparts=1 should be used for single-path payments instead of a layer

Fixes #8871

The auto.no_mpp_support layer was used to force single-path payments
for destinations that don't support MPP. Since maxparts=1 already
switches to the single-path algorithm, the layer is redundant.

Changes:
- askrene: remove remove_small_channel_layer() and auto.no_mpp_support
  handling from layer validation, creation, and algorithm override
- xpay: when disable_mpp is set, send maxparts=1 to getroutes instead
  of adding the auto.no_mpp_support layer
- tests: update test_getroutes_single_path, test_excessive_fee_cost,
  and test_impossible_payment to use maxparts=1 instead of the layer
- docs: update getroutes.json to describe three automatic layers and
  point to maxparts=1 for single-path payments

Fixes ElementsProject#8871
@madelinevibes madelinevibes added BOUNTY! 🫰 A bounty is available for this PR Status::Ready for Review The work has been completed and is now awaiting evaluation or approval. labels May 13, 2026
@madelinevibes madelinevibes added this to the v26.09 milestone May 13, 2026
@madelinevibes

Copy link
Copy Markdown
Collaborator

@ThomsenDrake are you able to resovle the conflicts so we can make sure this gets into 26.09 please?

…-mpp

# Conflicts:
#	doc/schemas/getroutes.json
#	plugins/askrene/askrene.c
#	plugins/xpay/xpay.c
#	tests/test_askrene.py
@Lagrang3

Copy link
Copy Markdown
Collaborator

auto.no_mpp_support was deprecated in #9110
https://github.com/ElementsProject/lightning/pull/9110/changes#diff-3a841e842d4eb516a9582457829219b4745040d0d248c636144bfb8e6460ec99R26

@madelinevibes

Copy link
Copy Markdown
Collaborator

@ThomsenDrake Unfortunately the work asked for in the issue was complete in an earlier PR. We are grateful for your efforts and contributions to CLN! Please contact me: Carrier pigeon and/or email madeline@blockstream.com so we can send you a bounty to acknowledge the work you did.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BOUNTY! 🫰 A bounty is available for this PR Status::Ready for Review The work has been completed and is now awaiting evaluation or approval.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Deprecate auto.no_mpp layer in askrene

3 participants