Since the lsat code was copied over to aperture a while ago for other
projects to use as well, we should migrate over to that shared code
also. This will give us the recently added "remove token if payment
failed and try again" feature for free along with some other small
updates to the lsat package.
In an effort to surface more information about why autoloop is not
executing, we add an error when suggest swaps is called with no rules.
In other cases we can surface a reason enum with each rule that is set,
but in the case where we have no rules, there are no results to
accompany with reasons.
As we add more paramters to the liqudity manager, it will become more
difficult to include them in a single cli endpoint with rules. This
commit renames the existing setparam command (which is only used for
rules at present), so that we can have a dedicated paramters cli
command for all the new values we are adding.
As we only use the readMacaroon function inside getClientConn where we
have an error return value anyway, we might as well pass the error along
correctly instead of failing hard directly.
To provide more information about swaps, we add a failure reason field
to our swaps. We do not extend our existing state enum to remain
backwards compatible.
With the restriction in place, it is not possible to use the
--conf_target and --fast flag at the same time. To avoid similar
problems in the future, the check for the number of amounts is
removed completely.