lightninglabs / lightninglabs/pool

CLI usability: make use of units (order creation, display of balances)

Open
#172 0 comments 5 reactions 0 assignees View on GitHub
beginner feature request freebie
Dominant language
Go
Stars
259
Forks
51
PR merge metrics
No merged PRs in 30d

Description

When submitting an order, you need to submit a balance as a multiple of 100,000 satoshis (which is a unit). However, the CLI still asks for satoshis, and also shows satoshis in other places where a unit would help (in addition to the satoshis). From a technical point of view this is no issue at all, as it is clear which value is expected. Furthermore, converting between units and satoshis is straightforward.

However, as a human being who uses the CLI, I'm quite sick of counting zeros, and finding the number I need to change in order to make my amount a whole unit. Please make it possible to submit an order by specifying the number of units.

Current:
```
pool orders submit ask 12200000 xxx --interest_rate_percent=0.5 --lease_duration_blocks=2016
```

Proposal:
```
pool orders submit ask --units 122 --acct_key xxx --interest_rate_percent=0.5 --lease_duration_blocks=2016
```

Contributor guide

No contributing guide indexed for this repository

Research direction

Start with the `pool orders submit` CLI entry point and review the other CLI locations that display balances. Confirm how unit values should coexist with satoshis, then verify that order creation accepts `--units` and that relevant balance displays include units without losing satoshi values.

Written by the indexing model from the issue text.

Assessment

Tech stack
go
Domain
cli
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.