The timestamp in the file didn't match the comment or the block height
(this doesn't break anything; the timestamp is only used for future
block arrival estimates).
This header is stupid and gross and is only used from wallet2. Remove
it from common/ to contain the damage within wallet2.
simplewallet.cpp includes it just for fun, but never actually uses it,
because why not?
This `getKeyFromBlockchain` function is completely moronic: it doesn't
do anything with its `reference_index`, and has a commented description
that doesn't match the actual implementation at all.
Moreover the `reference_index` argument, at once place here, is passed a
*function pointer cast to a size_t*. A generous interpretation is the
author knew that it wasn't being used, and thus could be passed the
abitrary address of a function that happens to return a random value --
but it's all fine because the argument isn't used, right?
Replace it with a .randomize() on ctkey that does the same thing, but
with 97% less moron.
This code is beyond pathetic. I am starting to see why some people need
Rust to guard their incompetence away from the code they write.
The logging refactor brought in some changes to how the logs are
created and as a result logs were polluting the command line where wallet2 was
displaying information. This makes the logging for wallet only to file
and stdout is reserved to the wallet to communicate to the user.
`get_service_nodes` no longer includes the `"reserved"` field if there
is no unfilled reservation, but wallet2 was expecting it.
This makes it okay with not having it.
Along the way this converts various `[]` to `.at()` to throw proper
exceptions when the key being accessed doesn't exist.
They should not have a body set (even if empty), but did, causing the
request handler to try to parse it as json and failing.
Fixes it to only set the body to a string if we actually have a
non-empty body to set.
- Adds script to extract markdown from the rpc comments to build a docs
page suitable for docsify.
- Split up daemon rpc docs logically into sections
- Reformat (mostly rewrapping) various docs entries
- Add examples, many of which are live-fetched at documentation
generation time.
- Mark various required options as `required{...}` so that they produce
an error if not provided in a request.
Using string_view is slightly faster as it lets us get a view directly
into nlohmann's string value, rather than making an intermediate copy
into a temporary string.