Skip to content

Commit

Permalink
Remove TODOs from README.md
Browse files Browse the repository at this point in the history
Tracking these through issues is better.

Also, `rustfmt` only needs to be called on top-level files
(see rust-lang/rustfmt#2426). It does
need to be called on every example, though, as those count as top-level
files.

Mention that signed GPG commits are preferred.

Tree-SHA512: 5e4a308e71a6dd437a93f337820eb817185c235bb2796bcf28d91e1e45f91cbce5dc7e305e7adc7ee96c4292ab91fa89eb932a0b0007f98191740a9d15ddb03f
  • Loading branch information
laanwj committed Sep 6, 2018
1 parent 7c93d07 commit aaa1155
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 23 deletions.
25 changes: 3 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,30 +58,11 @@ Be aware that the API (of rust-clighting-rpc, but also that of c-lightning
itself) is not finalized. This means that it may change from version to version and break your
compile, sorry!

# To do

- verify use of `i64` versus `u64` in API
- document low and high level handling
- document error handling
- reproducible functional test that exercises against actual lightning instances (regtest?)
- a better way to get at the data for failed payments

```
"code" : 205, "message" : "Could not find a route", "data" : ...
```

`data` could be parsed into a structure, but this depends on the kind of error

- the API could make more use of enums where the possible values are known; for example the
`addresstype` parameter to `newaddr`, but also in returned structures. This has to be weighted
against flexibility, though, in case the API is extended later.

- decide on `&str` versus `String` on high-level API (but at least make sure it is consistent)

# Style guidelines
# Contributing guidelines

- Four spaces
- Call `rustfmt src/*.rs` before committing
- Call `rustfmt src/lib.rs examples/*.rs` before committing
- If you can, GPG-sign at least your top commit when filing a PR

# Credits

Expand Down
6 changes: 5 additions & 1 deletion examples/ex_1.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ fn main() {
println!("getinfo result: {:?}", client.getinfo().unwrap());

for style in &["perkb", "perkw"] {
println!("feerates {}: {:?}", style, client.feerates(style.to_string()).unwrap());
println!(
"feerates {}: {:?}",
style,
client.feerates(style.to_string()).unwrap()
);
}
}

0 comments on commit aaa1155

Please sign in to comment.