Commit Graph

9896 Commits

Author SHA1 Message Date
Jason Rhinelander 186db9ab07
Fix compiler warning about sign mismatch 2023-04-28 16:20:17 -03:00
Jason Rhinelander 0cef2a9491
Fix horrible tr() in wallet_api; remove boost::format
wallet_api pretend to have `tr()` but really didn't: instead it had it
via a do-nothing macro, but the macro leaked into other places when
headers got sorted that caused all sorts of pain.

This cleans out some of the garbage.
2023-04-13 17:15:13 -03:00
Jason Rhinelander 67818e7cbf
Manual reformatting and post-formatting fixes
clang-format resulted in some screwy reformatting, particularly with
post-commended fields, and also exposed various missing header includes
when re-sorting headers.

This commit contains various small fixes and improvements to deal with
the formatting issues.
2023-04-13 17:15:12 -03:00
Jason Rhinelander 13409ad00e
run clang format 2023-04-13 17:15:12 -03:00
Sean 3fec56a7c5
Merge pull request #1630 from darcys22/wallet3-txextra
Wallet3 txextra
2023-03-24 15:50:33 +11:00
Sean Darcy 1fcc4b0e59 upsert instead of update for wallet keys 2023-03-24 04:04:21 +00:00
Sean Darcy 09ca536a13 blob_binder instead of manual binding params to query 2023-03-24 03:17:37 +00:00
Sean Darcy f091e5aadf remove unnecessary semicolons from SQL queries 2023-03-24 03:06:16 +00:00
Sean Darcy 7c01382439 removes unused OXEN_RPC_DOC_INTROSPECT from wallet3 2023-03-24 03:04:04 +00:00
Jason Rhinelander a27d9b69bb
Merge pull request #1628 from jagerman/seed-node-updates
Seed nodes updates
2023-03-24 13:34:12 +11:00
Sean Darcy 49766634a4 rename db_schema to walletdb 2023-03-24 00:10:09 +00:00
Sean Darcy 1a6087b2d1 statusbar to command line 2023-03-24 00:10:09 +00:00
Sean Darcy 6959a2478f get address implemented in cli wallet 2023-03-24 00:10:09 +00:00
Sean Darcy 1aafc767ad implement unlocked balance 2023-03-24 00:10:09 +00:00
Sean Darcy 12d77b3456 load keyring into wallet using initializer 2023-03-24 00:10:09 +00:00
Sean Darcy a0211fd16c metadata table changed from 1xN to Nx1 2023-03-24 00:10:03 +00:00
Sean Darcy c95806223d blobs for keys in db 2023-03-15 09:13:18 +11:00
Sean Darcy 3648ef28b2 Cleanup of wallet3 code 2023-03-15 09:13:07 +11:00
Sean Darcy ccbd9e82a5 remove newlines from logging 2023-03-07 10:46:19 +11:00
Sean Darcy cc2388712f cleanup of wallet3 code - change to db schema to remove keyring object 2023-03-02 12:32:39 +11:00
Sean Darcy 501eca5d87 wallet3 python cleanup, rounding for balance, lokinet ons buy split into years 2023-03-02 08:45:46 +11:00
Sean Darcy 2e6b96afbc ons buy and ons update mapping 2023-03-01 15:56:35 +11:00
Sean Darcy 31dd71ce6f implements ons_names_to_owners, modifys so it only takes a single name 2023-03-01 07:50:42 +11:00
Sean Darcy 53388ee8a1 up decoys in stub 2023-02-23 08:49:46 +11:00
Sean Darcy 03e18fcb55 Introduces Subaddresses to Wallet3 2023-02-16 08:18:09 +11:00
Sean Darcy 8a577a4bc7 Introduces OMQ to cli and additional commands 2023-02-16 08:17:55 +11:00
Sean Darcy 966c172d59 introduces logging to wallet3 2023-02-15 10:37:42 +11:00
Sean 72f795a5c5
Merge pull request #1631 from darcys22/noisy-log
Silency noisy logs
2023-02-15 10:33:41 +11:00
Sean Darcy ef584b575e Silency noisy logs 2023-02-10 16:10:30 +11:00
Jason Rhinelander 3a2ddb0ccd
Replace defunct OVH servers with another OPTF server 2023-01-31 20:25:53 -04:00
Jason Rhinelander 97b6fa5cba
Updated my personal server IP as it has moved 2023-01-31 13:24:53 -04:00
Jason Rhinelander 2956a10351
Schedule 19.3 hard spoon
- Scheduled for Feb 9th, 0:00 UTC.
- Bump required lokinet version to latest stable
- Bump SS version to 2.5.0
2023-01-24 11:37:25 -04:00
Jason Rhinelander 0652014573
Fix HF19.2 timestamp
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).
2023-01-24 11:32:51 -04:00
Sean b50067ea20
Merge pull request #1597 from jagerman/cleanups
Cleanups
2023-01-16 07:08:54 +11:00
Jason Rhinelander f6bd60c891
Remove bitrotten headers 2023-01-12 19:51:37 -04:00
Jason Rhinelander aaebf9d9d7
Remove epee/time_helper
It's included in a bunch of places, but only actually half-used in one,
which is easily replaced with `<chrono>` and tools::friendly_duration.
2023-01-12 19:51:37 -04:00
Jason Rhinelander 9dc312b0d9
Move gross single-macro-only "header" into wallet2
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?
2023-01-12 19:51:36 -04:00
Jason Rhinelander 53b981b865
Fix moronic code
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.
2023-01-12 19:51:36 -04:00
Jason Rhinelander 8020f29e25
Replace std::tuple<A, B> with std::pair<A, B>
Tuple is general purpose, but also heavier, so prefer pair when it is a
pair.
2023-01-12 19:51:36 -04:00
Jason Rhinelander d16bb75075
Cure std's
One should be careful when dealing with std's; this commit reduces the
spread of std's into places they don't belong.
2023-01-12 19:51:36 -04:00
Sean Darcy 7cab3c4b19 Disable logging to stdout for wallet2
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.
2023-01-13 10:26:16 +11:00
Jason Rhinelander ca5b3a24fa
Move 2023-01-11 19:47:13 -04:00
Jason Rhinelander 8a16ab664c
Handle missing total_reserved
Like reserved, it is omitted when not different than total_contributed.
2023-01-11 19:29:34 -04:00
Jason Rhinelander 2953502cf4
Small optimizations/cleanups 2023-01-11 19:10:45 -04:00
Jason Rhinelander 0b746215d3
Fix wallet2 staking
`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.
2023-01-11 19:07:11 -04:00
Jason Rhinelander e42414c8e3
Fix GET requests
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.
2023-01-11 16:46:21 -04:00
Jason Rhinelander a3ecb3cfa6
Revert wallet2 output blacklist retrieval
Wallet2 needs to keep using the binary endpoint as we don't have (or,
really, want) a non-binary version for wallet2 to use.
2023-01-11 16:09:06 -04:00
Jason Rhinelander 06d1c1dbb3
Remove can-be-empty on ss/lokinet ping pubkey handling 2023-01-11 16:08:38 -04:00
Jason Rhinelander 38e2b1518e
Fix ping pubkey_ed25519 parameter name
SS and Lokinet are using pubkey_ed25519 instead of ed25519_pubkey; fix
it to match what they are sending.
2023-01-11 16:08:38 -04:00
Jason Rhinelander 955692b72d
Lower pre-request rpc access logging to debug level 2023-01-11 14:31:50 -04:00