Commit graph

454 commits

Author SHA1 Message Date
hinto.janai
b2b7e93e4c
json-rpc fixes
Some checks are pending
Deny / audit (push) Waiting to run
2024-12-19 20:41:50 -05:00
hinto.janai
114a5db52e
fix conflict 2024-12-19 18:42:17 -05:00
hinto.janai
d47f8ec7dc
fix doc tests 2024-12-19 18:38:08 -05:00
hinto.janai
dff77e8bed
fix get_txid for /get_outs
miner transaction was not accounted for
2024-12-19 18:11:00 -05:00
hinto.janai
cb6fdb76e4
HexVec 2024-12-19 17:22:35 -05:00
hinto.janai
ed8de29504
txpool: all_hashes 2024-12-18 21:03:40 -05:00
hinto.janai
21e42c1f54
module cleanup 2024-12-18 20:26:54 -05:00
hinto.janai
aca28552ab
get_output_distribution 2024-12-18 18:09:01 -05:00
hinto.janai
ce6838bd6f
restricted json-rpc error 2024-12-17 18:39:05 -05:00
hinto.janai
3763dc9693
rpc-interface: add restricted invariant comments 2024-12-17 18:23:09 -05:00
hinto.janai
04cdc72f46
/get_blocks.bin 2024-12-17 18:16:03 -05:00
hinto.janai
f7f9063890
clippy 2024-12-16 20:49:20 -05:00
hinto.janai
3664e2f794
/get_output_distribution.bin 2024-12-16 20:48:06 -05:00
hinto.janai
8cd319cc45
/get_o_indexes.bin 2024-12-16 20:30:52 -05:00
hinto.janai
541302ea07
get_blocks_by_height, shared::get_outs 2024-12-16 20:21:00 -05:00
hinto.janai
0b3ee2d1d1
finish other draft 2024-12-16 17:56:27 -05:00
hinto.janai
805f475083
/get_transaction_pool_stats 2024-12-13 20:21:11 -05:00
hinto.janai
c5abf9bb98
/get_transaction_pool 2024-12-13 20:14:16 -05:00
hinto.janai
c924f24765
/peerlist 2024-12-13 19:50:19 -05:00
hinto.janai
b3314d4981
/send_raw_transaction, /save_bc, response_base 2024-12-13 19:30:25 -05:00
hinto.janai
d4b30333bb
most of /send_raw_transaction
Some checks failed
Deny / audit (push) Has been cancelled
2024-12-13 16:43:39 -05:00
hinto.janai
c38daa4497
/get_transactions hex 2024-12-13 15:36:11 -05:00
hinto.janai
ab4822c660
!! 2024-12-13 15:16:26 -05:00
hinto.janai
a359eed8be
/is_key_image_spent 2024-12-11 20:52:40 -05:00
hinto.janai
c3bc9b26ec
/get_transactions 2024-12-11 19:16:34 -05:00
hinto.janai
b402c82557
json_rpc: get_block_template 2024-12-11 16:30:37 -05:00
hinto.janai
1719d7db84
return defaults, hex test
Some checks failed
Deny / audit (push) Has been cancelled
2024-12-10 20:49:39 -05:00
hinto.janai
3a799219b8
fix type defaults, use Hex 2024-12-10 20:09:33 -05:00
hinto.janai
89191ce3bc
fix clippy 2024-12-08 16:11:43 -05:00
hinto.janai
bf5e863f18
remove ::<N>
Some checks failed
Deny / audit (push) Has been cancelled
2024-12-06 20:10:56 -05:00
hinto.janai
2de9a019c6
fix json-rpc handlers 2024-12-06 19:59:38 -05:00
hinto.janai
3c25374b03
architecture book 2024-12-06 19:30:17 -05:00
hinto.janai
f2e7af779f
move types, fix orphan impl + cyclic dependency 2024-12-06 19:19:14 -05:00
hinto.janai
5b8cacd6b3
!! 2024-12-06 18:02:05 -05:00
hinto.janai
d1c1025238
rpc: move json-rpc types away from macros
Some checks are pending
Deny / audit (push) Waiting to run
2024-12-06 11:29:55 -05:00
hinto.janai
a1903f33b0
clippy fix 2024-12-06 09:26:20 -05:00
hinto.janai
20e599fc72
type fixes, move fn to -helper 2024-12-06 09:23:45 -05:00
hinto.janai
568a276b7f
rpc-types -> types pt. 2
Some checks are pending
Deny / audit (push) Waiting to run
2024-12-05 20:45:27 -05:00
hinto.janai
2104bb0e17
cuprate_types::rpc, from module for cuprate_rpc_types 2024-12-05 16:05:22 -05:00
hinto.janai
0b50091b5d
merge diffs from https://github.com/Cuprate/cuprate/pull/272
Some checks are pending
Deny / audit (push) Waiting to run
2024-12-05 09:29:33 -05:00
hinto.janai
edaf6275da
Merge branch 'main' into json 2024-12-04 20:43:10 -05:00
7b8756fa80
cuprated: P2P protocol request handler (#303)
Some checks failed
CI / typo (push) Has been cancelled
CI / ci (macos-latest, stable, bash) (push) Has been cancelled
CI / fmt (push) Has been cancelled
CI / ci (ubuntu-latest, stable, bash) (push) Has been cancelled
CI / ci (windows-latest, stable-x86_64-pc-windows-gnu, msys2 {0}) (push) Has been cancelled
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* add cuprated skeleton

* fmt and add deny exception

* add main chain batch handler

* add blockchain init

* very rough block manager

* misc changes

* move more config values

* add new tables & types

* add function to fully add an alt block

* resolve current todo!s

* add new requests

* WIP: starting re-orgs

* add last service request

* commit Cargo.lock

* add test

* more docs + cleanup + alt blocks request

* clippy + fmt

* document types

* move tx_fee to helper

* more doc updates

* fmt

* fix imports

* remove config files

* fix merge errors

* fix generated coins

* handle more p2p requests + alt blocks

* clean up handler code

* add function for incoming blocks

* add docs to handler functions

* broadcast new blocks + add commands

* add fluffy block handler

* fix new block handling

* small cleanup

* increase outbound peer count

* fix merge

* clean up the blockchain manger

* add more docs + cleanup imports

* fix typo

* fix doc

* remove unrelated changes

* add `get_objects` handler

* add `get_chain` handler

* add `fluffy_missing_txs` handler

* add `new_fluffy_block` handler

* improve interface globals

* manger -> manager

* enums instead of bools

* move chain service to separate file

* more review fixes

* sort imports + docs

* init dandelion integration

* add dandelion start function

* finish incoming tx handler

* Add tx blob hash table

* Add missing txpool requests

* handle duplicate stem txs

* check txpool on incoming block

* add request to remove tx in new blocks from the pool

* tell the txpool about incoming blocks

* fix merge

* typos

* remove blockchain height from txpool

* fix merge

* fix merge

* handle incoming txs in p2p request handler

* Allow `IncomingTxHandler` to be given later

* add p2p clearnet init

* fix build

* misc changes

* doc updates

* more doc updates

* sort imports

* review changes

* Result -> DbResult

* use `NonZero`

* review fixes

* remove `rust-2024-compatibility` lint
2024-12-03 20:21:05 +00:00
ecd077b402
cuprated: config & args (#304)
* init config

* split sections

* finish initial config.

* fix clap

* misc changes

* fix doc

* fix test & clippy

* fix test 2

* try fix windows

* testing

* testing 2

* fix windows test

* fix windows: the remix.

* review comments

* fix imports

* rename & fix default config file

* fix cargo hack

* enable serde on `cuprate-helper`

* changes from matrix chats

* fix ci

* fix doc

* fix doc test

* move Cuprated.toml

* remove default.rs

* `size` -> `bytes`

* `addressbook_path` -> `address_book_path`

* fix config output

* fix ci

* Update binaries/cuprated/src/config/args.rs

Co-authored-by: hinto-janai <hinto.janai@protonmail.com>

---------

Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-12-03 15:17:21 +00:00
hinto-janai
38541dbfda
workspace: add/fix 1.83 lints (#353)
Some checks failed
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
CI / fmt (push) Has been cancelled
CI / typo (push) Has been cancelled
CI / ci (macos-latest, stable, bash) (push) Has been cancelled
CI / ci (ubuntu-latest, stable, bash) (push) Has been cancelled
CI / ci (windows-latest, stable-x86_64-pc-windows-gnu, msys2 {0}) (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* 1.83 `cargo clippy --fix`

* fix type complexity, add `DbResult`

* clippy fix

* redb fix

* Update consensus/context/src/difficulty.rs

Co-authored-by: hinto-janai <hinto.janai@protonmail.com>

---------

Co-authored-by: Boog900 <boog900@tutanota.com>
2024-11-28 19:53:59 +00:00
hinto-janai
01150ab84c
rpc/types: fix epee deserialization for GetBlocksResponse (#345)
Some checks failed
CI / fmt (push) Waiting to run
CI / typo (push) Waiting to run
CI / ci (macos-latest, stable, bash) (push) Waiting to run
CI / ci (ubuntu-latest, stable, bash) (push) Waiting to run
CI / ci (windows-latest, stable-x86_64-pc-windows-gnu, msys2 {0}) (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
Deny / audit (push) Waiting to run
Architecture mdBook / build (push) Has been cancelled
* header + flatten

* fix optional values

* `fn error() -> String` -> `error!() -> &'static str`

* extract out `PoolInfo`

* fix cargo hack
2024-11-27 23:04:58 +00:00
hinto.janai
a3fa638d91
fix bans
Some checks failed
Deny / audit (push) Has been cancelled
2024-11-26 21:05:57 -05:00
hinto.janai
1a079c856e
lint/todo fixes 2024-11-26 20:48:53 -05:00
hinto.janai
8d5f779ec3
p2p: remove tmp AddressBookRequest::NextNeededPruningSeed 2024-11-26 20:22:02 -05:00
hinto.janai
ff48fb4679
doc fix 2024-11-26 19:48:28 -05:00
hinto.janai
916d593024
fixes 2024-11-26 19:37:35 -05:00