Skip to content

Commit

Permalink
rpcserver+server: bump minimum required lnd version to v0.14.3-beta
Browse files Browse the repository at this point in the history
With lnd 0.15.0 almost out of the door, it is reasonable for us to ask
users to be on the latest 0.14.x version.
We use the walletrpc.SignPsbt method in Pool which was added in 0.14.2.
  • Loading branch information
guggero committed Jun 10, 2022
1 parent cba9ec0 commit 95a0690
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 29 deletions.
20 changes: 5 additions & 15 deletions rpcserver.go
Original file line number Diff line number Diff line change
Expand Up @@ -1311,21 +1311,11 @@ func (s *rpcServer) SubmitOrder(ctx context.Context,
// new features as they're available, while still supporting older
// versions of lnd.
chanTypeSelector := order.WithDefaultChannelType(func() order.ChannelType {
// If they didn't specify a value, then we'll select one based
// on the version of lnd we detect.
verErr := lndclient.AssertVersionCompatible(
s.server.lndServices.Version, scriptEnforceVersion,
)
if verErr == nil {
// TODO(guggero): Use order.ChannelTypeScriptEnforced
// here as soon as a large percentage of ask orders
// support script enforced channel types to not cause a
// market segregation for lnd 0.14.x or later users
// without them being aware of why their bids aren't
// getting matched.
return order.ChannelTypePeerDependent
}

// TODO(guggero): Use order.ChannelTypeScriptEnforced here as
// soon as a large percentage of ask orders support script
// enforced channel types to not cause a market segregation for
// lnd 0.14.x or later users without them being aware of why
// their bids aren't getting matched.
return order.ChannelTypePeerDependent
})

Expand Down
16 changes: 2 additions & 14 deletions server.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,8 @@ var (
// required in lnd to run pool.
minimalCompatibleVersion = &verrpc.Version{
AppMajor: 0,
AppMinor: 12,
AppPatch: 0,
AppMinor: 14,
AppPatch: 3,

// We don't actually require the invoicesrpc calls. But if we
// try to use lndclient on an lnd that doesn't have it enabled,
Expand All @@ -51,18 +51,6 @@ var (
"signrpc", "walletrpc", "chainrpc", "invoicesrpc",
},
}

// scriptEnforceVersion is the version of lnd that enabled lease duration script
// enforcement as a new channel type. We'll use this to decide what
// order type to default to.
scriptEnforceVersion = &verrpc.Version{
AppMajor: 0,
AppMinor: 14,
AppPatch: 0,
BuildTags: []string{
"signrpc", "walletrpc", "chainrpc", "invoicesrpc",
},
}
)

// Server is the main poold trader server.
Expand Down

0 comments on commit 95a0690

Please sign in to comment.