hinto-janai
aeb070ae8d
Replace OnceLock
+ fn
with LazyLock
( #256 )
...
* `consensus/`
* `helper/`
* `test-utils/`
* `storage/`
* fix docs + tests + lints
* decomposed_amount: remove `LazyLock`
* clippy
2024-08-20 22:53:32 +01:00
hinto-janai
59adf6dcf8
std::mem::{size,align}_of
-> {size,align}_of
(#254 )
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
2024-08-10 00:09:25 +01:00
hinto-janai
bca062d2f5
workspace: add 1.78..=1.80
lints ( #253 )
...
cargo.toml: add lints
2024-08-10 00:08:56 +01:00
hinto-janai
ca3b149b39
ci: fix book CI ( #252 )
...
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
* ci: fix book ci
* ci: add `--locked`
2024-08-09 20:44:53 +01:00
0041650fd1
books: change some definitions ( #251 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
Monero mdBook / build (push) Has been cancelled
update some definitions
2024-08-09 00:56:41 +01:00
be2f3f2672
Consensus: move more types to types
( #250 )
...
* move `HardFork` to `types`
* fmt
* fix tests & doc
* fmt
* fix clippy
* move transaction verification data
* misc fixes
* doc fixes
* update README.md
* review fixes
2024-08-09 00:56:13 +01:00
hinto-janai
fafa20c20f
architecture-book: fill RPC
section ( #243 )
...
Architecture mdBook / 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
Doc / build (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
* books: add `rpc` skeleton
* json-rpc
* types section
* differences
* interface
* typos
* differences: add `json-formatting.md`
* rpc: small fixes
* appendix: add `cuprate-rpc-handler` to crate list
* differences: remove extra fields section, add more info
* differences: add `id:0` section
2024-08-08 00:15:22 +01:00
hinto-janai
eb65efa7fb
ci: add book build tests ( #249 )
...
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
Audit / audit (push) Has been cancelled
Deny / audit (push) Has been cancelled
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: add book build tests
* ci: add `mdbook-svgbob`
* ci: `|`
2024-08-07 02:04:11 +01:00
8227c28604
update monero-serai ( #201 )
...
* update monero-serai
* update monero-serai + change height to `usize`
* fix merge
* fix merge
* fix doc
* fix clippy take 2
* misc changes
* move RPC imports to dev deps
* handle miner txs when calculating fee
* Update consensus/rules/src/blocks.rs
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* Update consensus/rules/src/transactions.rs
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* Update storage/blockchain/src/ops/tx.rs
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* Update test-utils/src/data/free.rs
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* fixes
* fix clippy
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-08-07 00:48:53 +01:00
hinto-janai
27767690ca
rpc: impl cuprate-rpc-interface
( #233 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
* fixed-bytes: add `serde`, document feature flags
* fixed-bytes: add derives
* rpc: add `as _` syntax to macro
* rpc: use `ByteArrayVec` and `ContainerAsBlob` for binary types
* fixed-bytes: re-add derives
* rpc-types: dedup default value within macro
* readme: fixed bytes section
* types: custom epee - `BlockCompleteEntry`
* types: custom epee - `KeyImageSpentStatus`
* types: custom epee - `PoolInfoExtent`
* types: add `Status::Other(String)` variant
* types: custom epee - `TxEntry`, add `read_epee_field` macro
* bin: custom epee - `GetBlocks`
* types: add `serde.rs`
* misc: make `TxEntry` an `enum`, impl serde
* misc: `unimplemented!()` for `TxEntry`'s epee
* types: add `BlockCompleteEntry`
* rpc: replace `BlockCompleteEntry` with `cuprate-types`
* types: document `BlockCompleteEntry`
* bin: fix `number_of_fields` for `GetBlocksResponse`
* misc: add `Distribution`
* distribution: add todo
* misc fixes
* readme: add `(De)serialization invariants`
* distribution: compress variants
* types: add `block_complete_entry.rs`
* net: fix imports
* p2p: fix imports
* turn off default-features
* p2p: fix imports
* misc fixes
* Update net/wire/Cargo.toml
Co-authored-by: Boog900 <boog900@tutanota.com>
* distribution: module doc
* wire: re-export types
* test-utils: add `crate::rpc::types` module
* test-utils: conditional json doc-tests
* bin: use enum for `GetBlocksResponse`
* misc: use lowercase for stringify
* json: add test data, fix macro doc tests
* json: add all data
* other: add all data
* bin: add skeleton
* docs
* move type to correct file
* remove duplicated fields for custom epee
* rpc: `client/{client,constants}.rs` -> `client.rs`
* lib.rs: remove `clippy::module_inception`
* macros: add json doc test macro
* json: add some tests
* json: add doc-test for all types
* add all other JSON doc-tests
* move doc-test macros to files
* base: add doc-tests
* rpc: add `cuprate-rpc-interface` skeleton files
* traits
* json_rpc_method: add `.is_restricted()`
* add route fn signatures
* types: add rpc enums
* interface: routes, types
* interface: simplify routes
* rewrite interface fns
* types: remove `()` type alias, add `(restricted)`
* types: add `other::InPeers`
* interface: routes
* types: fix `is_restricted()`
* interface: reorder short-circuit bool
* clean up traits/bounds
* types: remove `axum` feature
* interface: cleanup unused imports
* interface: call handler in routes
* json: TODO distribution test
* interface: readme intro
* combine `RpcHandler` + `RpcService`, add `RpcDummyHandler`
* interface: readme docs + test
* `IsRestricted` -> `RpcCall`
* fix no input route problem
* interface: `RpcHandlerDummy` docs
* interface: crate docs
* replace `create_router` with `RouterBuilder`
* types: docs
* types: doc `JsonRpc{Request,Response}`
* types: readme docs
* interface: doc `route/`
* interface: fix `todo!()`
* interface: allow customizing HTTP method on route functions
* interface: fix tests
* fix derives
* Update rpc/interface/README.md
Co-authored-by: Boog900 <boog900@tutanota.com>
* Update rpc/interface/README.md
Co-authored-by: Boog900 <boog900@tutanota.com>
* interface: make `RpcHandler`'s `Future` generic
* interface: add JSON-RPC notification todo
* formatting
* interface: use associated type bound for `RpcHandler`'s `Future`
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-08-06 00:50:38 +01:00
1a178381dd
Storage: split the DB service abstraction ( #237 )
...
* split the DB service abstraction
* fix ci
* misc changes
* Apply suggestions from code review
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* review fixes
* Update storage/service/Cargo.toml
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* Update storage/service/Cargo.toml
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* fix clippy
* fix doc
* `bc` -> `blockchain`
* doc fixes
* Update storage/service/README.md
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* cargo fmt
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-08-05 21:47:30 +01:00
hinto-janai
bd375eae40
rpc-types: add traits and enum
requests/responses ( #241 )
...
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 / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
apply diff
2024-08-01 22:04:22 +01:00
hinto-janai
dced4ed7ec
architecture-book: add Crates
section ( #239 )
...
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 / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* add `cuprate-crates.md`
* fix links
* Update books/architecture/src/appendix/crates.md
Co-authored-by: Boog900 <boog900@tutanota.com>
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-07-30 21:53:27 +01:00
86d1f408d8
books: fix typo ( #240 )
...
fix typo
2024-07-30 20:12:09 +01:00
b44c6b045b
Consensus: add alt-chain handling ( #214 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* add `pop_blocks` to the difficulty cache
* add a rolling median struct
* use RollingMedian in weight cache
* add pop_blocks to weight cache
* add alt context cache
* add getting alt RX vms
* rework alt cache
* add alt block verify function
* keep alt caches around
* add alt checked alt blocks to the cache
* check the alt blocks timestamp
* add docs + cleanup code
* add popping blocks from the context cache
* finish popping blocks + fix tests
* fix doc
* add a test popping blocks from HF cache
* add a request to clear alt caches
* add back lint
* Apply suggestions from code review
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* review fixes
* small changes
* change panic doc
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-07-29 01:13:08 +01:00
hinto-janai
a2bca1b889
rpc: add JSON doc-tests ( #232 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
* fixed-bytes: add `serde`, document feature flags
* fixed-bytes: add derives
* rpc: add `as _` syntax to macro
* rpc: use `ByteArrayVec` and `ContainerAsBlob` for binary types
* fixed-bytes: re-add derives
* rpc-types: dedup default value within macro
* readme: fixed bytes section
* types: custom epee - `BlockCompleteEntry`
* types: custom epee - `KeyImageSpentStatus`
* types: custom epee - `PoolInfoExtent`
* types: add `Status::Other(String)` variant
* types: custom epee - `TxEntry`, add `read_epee_field` macro
* bin: custom epee - `GetBlocks`
* types: add `serde.rs`
* misc: make `TxEntry` an `enum`, impl serde
* misc: `unimplemented!()` for `TxEntry`'s epee
* types: add `BlockCompleteEntry`
* rpc: replace `BlockCompleteEntry` with `cuprate-types`
* types: document `BlockCompleteEntry`
* bin: fix `number_of_fields` for `GetBlocksResponse`
* misc: add `Distribution`
* distribution: add todo
* misc fixes
* readme: add `(De)serialization invariants`
* distribution: compress variants
* types: add `block_complete_entry.rs`
* net: fix imports
* p2p: fix imports
* turn off default-features
* p2p: fix imports
* misc fixes
* Update net/wire/Cargo.toml
Co-authored-by: Boog900 <boog900@tutanota.com>
* distribution: module doc
* wire: re-export types
* test-utils: add `crate::rpc::types` module
* test-utils: conditional json doc-tests
* bin: use enum for `GetBlocksResponse`
* misc: use lowercase for stringify
* json: add test data, fix macro doc tests
* json: add all data
* other: add all data
* bin: add skeleton
* docs
* move type to correct file
* remove duplicated fields for custom epee
* rpc: `client/{client,constants}.rs` -> `client.rs`
* lib.rs: remove `clippy::module_inception`
* macros: add json doc test macro
* json: add some tests
* json: add doc-test for all types
* add all other JSON doc-tests
* move doc-test macros to files
* base: add doc-tests
* json: TODO distribution test
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-07-28 21:43:16 +01:00
hinto-janai
7416164b19
workspace: fix lint error ( #234 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* cargo.toml: split `keyword_idents` lint
* dandelion-tower: fix doc
* fix doc/clippy
2024-07-25 22:47:39 +01:00
hinto-janai
929d19c450
rpc: custom epee for misc/bin types ( #229 )
...
* fixed-bytes: add `serde`, document feature flags
* fixed-bytes: add derives
* rpc: add `as _` syntax to macro
* rpc: use `ByteArrayVec` and `ContainerAsBlob` for binary types
* fixed-bytes: re-add derives
* rpc-types: dedup default value within macro
* readme: fixed bytes section
* types: custom epee - `BlockCompleteEntry`
* types: custom epee - `KeyImageSpentStatus`
* types: custom epee - `PoolInfoExtent`
* types: add `Status::Other(String)` variant
* types: custom epee - `TxEntry`, add `read_epee_field` macro
* bin: custom epee - `GetBlocks`
* types: add `serde.rs`
* misc: make `TxEntry` an `enum`, impl serde
* misc: `unimplemented!()` for `TxEntry`'s epee
* types: add `BlockCompleteEntry`
* rpc: replace `BlockCompleteEntry` with `cuprate-types`
* types: document `BlockCompleteEntry`
* bin: fix `number_of_fields` for `GetBlocksResponse`
* misc: add `Distribution`
* distribution: add todo
* misc fixes
* readme: add `(De)serialization invariants`
* distribution: compress variants
* types: add `block_complete_entry.rs`
* net: fix imports
* p2p: fix imports
* turn off default-features
* p2p: fix imports
* misc fixes
* Update net/wire/Cargo.toml
Co-authored-by: Boog900 <boog900@tutanota.com>
* distribution: module doc
* wire: re-export types
* bin: use enum for `GetBlocksResponse`
* misc: use lowercase for stringify
* remove duplicated fields for custom epee
* types: remove `should_write()` for custom epee
* bin: split `GetBlocksResponse` variant fields into structs
* misc: split `Distribution` variant fields into structs
* small fixes
* put all fields in `read_epee_field!`
* distribution: (de)compress during epee/serde (de)serialization
* distribution: leave (de)compression functions as `todo!()`
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-07-25 16:46:41 +01:00
hinto-janai
aa718e224f
test-utils: add crate::rpc::data
module ( #231 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* test-utils: add `crate::rpc::types` module
* test-utils: conditional json doc-tests
* json: add test data, fix macro doc tests
* json: add all data
* other: add all data
* bin: add skeleton
* docs
* move type to correct file
* rpc: `client/{client,constants}.rs` -> `client.rs`
* lib.rs: remove `clippy::module_inception`
2024-07-19 00:50:27 +01:00
hinto-janai
0a88ea13fc
books: architecture skeleton ( #224 )
...
* upstream https://github.com/hinto-janai/cuprate-architecture
* tab -> 4 spaces
2024-07-18 21:35:52 +01:00
88551c800c
Books: document p2p protocol ( #216 )
...
* add admin message definitions
* add block complete entry
* add protocol messages
* add most flows
* add final flows
* fix typos
* move link to epee
* review fixes
2024-07-18 21:34:56 +01:00
hinto-janai
6820da9848
types: add BlockCompleteEntry
( #230 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* types: add `block_complete_entry.rs`
* net: fix imports
* p2p: fix imports
* turn off default-features
* p2p: fix imports
* Update net/wire/Cargo.toml
Co-authored-by: Boog900 <boog900@tutanota.com>
* wire: re-export types
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-07-16 22:47:50 +01:00
hinto-janai
0910c0a231
rpc: use ByteArrayVec
and ContainerAsBlob
( #227 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (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
* fixed-bytes: add `serde`, document feature flags
* fixed-bytes: add derives
* rpc: add `as _` syntax to macro
* rpc: use `ByteArrayVec` and `ContainerAsBlob` for binary types
* fixed-bytes: re-add derives
* rpc-types: dedup default value within macro
* readme: fixed bytes section
2024-07-13 01:26:11 +01:00
hinto-janai
0a390a362a
storage: doc fixes ( #228 )
...
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
* database: doc fixes
* blockchain: doc fixes
* database: fix doc test
* database: readme fixes
* blockchain: ops fix
* blockchain: readme fix
2024-07-12 22:15:02 +01:00
hinto-janai
fbae3df203
storage: move table generator macro blockchain
-> database
( #222 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* move table generator macro `blockchain` -> `database`
* blockchain: fix imports
* docs
* fix import ordering
2024-07-11 14:20:56 +01:00
hinto-janai
824651c8cf
fixed-bytes: add serde
, document feature flags ( #226 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
* fixed-bytes: add `serde`, document feature flags
* manual impl `serde::Deserialize`
* add serde tests
2024-07-11 02:00:47 +01:00
hinto-janai
5aeb8af4b4
rpc: implement other JSON types ( #221 )
...
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
* `serde/epee` feature flags
* modify type generator macros
* add `defaults.rs`
* add `free.rs`
* add `misc` module
* modify `base.rs`, `contants.rs`
* remove `binary_string.rs`, `status.rs`
* fix macro usage
* impl `other.rs`
* base: re-add `AccessRequestBase`
* fix default functions
* tx_entry: fix link
* other: fix default functions
* Update rpc/types/src/other.rs
Co-authored-by: Boog900 <boog900@tutanota.com>
* Update rpc/types/src/other.rs
Co-authored-by: Boog900 <boog900@tutanota.com>
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-07-10 22:31:56 +01:00
hinto-janai
612938eae6
database: workaround redb
page freeing issue ( #225 )
...
* redb: `SyncMode::Fast` => `redb::Durability::Eventual`
* redb: fix clippy
* database: document `SyncMode`
2024-07-10 22:11:09 +01:00
hinto-janai
303c165df7
rpc: implement .bin
types ( #220 )
...
* `serde/epee` feature flags
* modify type generator macros
* add `defaults.rs`
* add `free.rs`
* add `misc` module
* modify `base.rs`, `contants.rs`
* remove `binary_string.rs`, `status.rs`
* fix macro usage
* impl `bin.rs`
* base: re-add `AccessRequestBase`
* fix default functions
* tx_entry: fix link
* bin: fix default functions
2024-07-10 21:19:19 +01:00
hinto-janai
ecbb5ad3dc
rpc: implement /json_rpc
types ( #219 )
...
* `serde/epee` feature flags
* modify type generator macros
* add `defaults.rs`
* add `free.rs`
* add `misc` module
* modify `base.rs`, `contants.rs`
* remove `binary_string.rs`, `status.rs`
* fix macro usage
* impl `json.rs`
* base: re-add `AccessRequestBase`
* fix default functions
* tx_entry: fix link
* json: fix default functions
* json: fix `on_get_block_hash`, `submit_block`
* json: `status` -> `block_id`
* json: fix `SubmitBlockRequest`
* json: fix `OnGetBlockHashResponse`
The serialized `result` field will come from our `json-rpc` crate,
so the inner type should be a `transparent` string.
* json: `Response` -> `ResponseBase` for `SubmitBlock`
* Update rpc/types/src/json.rs
Co-authored-by: Boog900 <boog900@tutanota.com>
* json: fix `SubmitBlockRequest` doc test
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-07-10 21:12:40 +01:00
hinto-janai
5c3258a6e3
workspace: add lints ( #133 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
add lints to workspace
2024-07-10 01:32:23 +01:00
dependabot[bot]
0d7b86abe3
build(deps): bump zerovec from 0.10.2 to 0.10.4 ( #217 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
Bumps [zerovec](https://github.com/unicode-org/icu4x ) from 0.10.2 to 0.10.4.
- [Release notes](https://github.com/unicode-org/icu4x/releases )
- [Changelog](https://github.com/unicode-org/icu4x/blob/main/CHANGELOG.md )
- [Commits](https://github.com/unicode-org/icu4x/commits/ind/zerovec@0.10.4 )
---
updated-dependencies:
- dependency-name: zerovec
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-09 23:03:13 +01:00
dependabot[bot]
03815efe29
build(deps): bump zerovec-derive from 0.10.2 to 0.10.3 ( #223 )
...
Bumps [zerovec-derive](https://github.com/unicode-org/icu4x ) from 0.10.2 to 0.10.3.
- [Release notes](https://github.com/unicode-org/icu4x/releases )
- [Changelog](https://github.com/unicode-org/icu4x/blob/main/CHANGELOG.md )
- [Commits](https://github.com/unicode-org/icu4x/commits/ind/zerovec-derive@0.10.3 )
---
updated-dependencies:
- dependency-name: zerovec-derive
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-07-09 23:01:31 +01:00
hinto-janai
136abf7edd
rpc: feature flags, macro changes, misc setup ( #218 )
...
* `serde/epee` feature flags
* modify type generator macros
* add `defaults.rs`
* add `free.rs`
* add `misc` module
* modify `base.rs`, `contants.rs`
* remove `binary_string.rs`, `status.rs`
* fix macro usage
* base: re-add `AccessRequestBase`
* fix default functions
* tx_entry: fix link
2024-07-09 22:58:02 +01:00
a82c08cc80
Storage: fix lifetimes ( #215 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Doc / deploy (push) Has been cancelled
* fix db lifetimes
* fix redb
* fix blockchain with redb
* add docs
2024-07-06 13:21:46 +01:00
d5c8eba1d8
P2P: API Improvements ( #168 )
...
Deny / audit (push) Has been cancelled
Doc / build (push) Has been cancelled
Audit / audit (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
* start handshaker builder
* finish builder
* remove borsh requirement
* fix poll_ready :/
* add more docs to builder
* more docs
* fix clippy
* merge fixes
* fix doc test
* fix imports
* cargo fmt
* split `PeerRequest` and `PeerResponse` enums up.
This splits them both into a protocol and admin enum
* add request handler file
* integrate request handler into connection
* fix docs
* doc updates
* add more docs
* fix docs
* misc changes
* review fixes
* fix merge
* add dummy file
* fix docs
* Update p2p/dandelion-tower/src/router.rs
* fix docs
2024-07-04 21:05:22 +01:00
hinto-janai
71131a4836
ci: fix doc.yml
( #213 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
Doc / build (push) Waiting to run
Doc / deploy (push) Blocked by required conditions
* types: remove borsh/serde
* blockchain: re-add optional serde
* doc.yml: remove `-D warnings`
2024-07-04 15:52:51 +01:00
hinto-janai
a8b58fa4db
ci: add doc.yml
( #203 )
...
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
* ci: add `doc.yml`
* update `{CONTRIBUTING,README}.md`
* readme: formatting
2024-07-03 22:38:47 +01:00
7c8466f4ba
Storage: add blockchain history requests ( #206 )
...
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
Audit / audit (push) Has been cancelled
Deny / audit (push) Has been cancelled
* Add database requests for chain history
* misc fixes
* review comments
* fix clippy
* add link and fix typo
* Apply suggestions from code review
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* add comment
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-07-02 23:08:19 +01:00
hinto-janai
6ce177aeca
storage: add key sorting ( #198 )
...
Audit / audit (push) Waiting to run
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
Deny / audit (push) Waiting to run
* database: modify `trait Key`, don't blanket impl
* heed: create `KeyHeed<T>` wrapper type
* fix backend/tests
* blockchain: `impl Key PreRctOutputId`
* database: `StorableStr`, docs, tests
* key: docs, cleanup
* fixes
* heed: simplify types
* storable: remove doc
* heed: use `INTEGER_KEY` instead of custom compare fn
* add docs, tests
* database: document `create_db` invariant
* key: `Lexicographic` -> `Default`
* redb: fix `clear_db` behavior
* fix docs
2024-07-01 20:24:48 +01:00
fb1f071faf
P2P: fix block downloader test ( #205 )
...
make sure timeout is non-zero
2024-07-01 20:23:59 +01:00
f91be58a7f
P2P: Fix freeze in D++ ( #204 )
...
* Fix d++ router freeze
* update docs
* fix imports
* fix clippy
* Update p2p/dandelion-tower/src/lib.rs
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-07-01 20:23:40 +01:00
dependabot[bot]
7e9891de5b
build(deps): bump curve25519-dalek from 4.1.2 to 4.1.3 ( #197 )
...
CI / ci (macos-latest, stable, bash) (push) Has been cancelled
Audit / audit (push) Has been cancelled
CI / fmt (push) Has been cancelled
CI / typo (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
Bumps [curve25519-dalek](https://github.com/dalek-cryptography/curve25519-dalek ) from 4.1.2 to 4.1.3.
- [Release notes](https://github.com/dalek-cryptography/curve25519-dalek/releases )
- [Commits](https://github.com/dalek-cryptography/curve25519-dalek/compare/curve25519-4.1.2...curve25519-4.1.3 )
---
updated-dependencies:
- dependency-name: curve25519-dalek
dependency-type: direct:production
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-06-26 22:59:11 +01:00
hinto-janai
a438279aa8
storage: split cuprate-blockchain
<-> cuprate-database
( #160 )
...
* storage: port some code `cuprate-blockchain` -> `database`
* database: remove `Tables` references
* database: remove old `cuprate-blockchain` type references
* find/replace `cuprate_blockchain` -> `database`, add `create_db()`
* database: fix redb
* database: use readme for docs, link in `lib.rs`
* database: fix `open_db_ro`, `open_db_rw`, `create_db` behavior
* database: add open table tests
* database: fix tests, remove blockchain specific references
* database: remove `ReaderThreads`, make `db_directory` mandatory
* initial `cuprate-blockchain` split
* fix doc links
* rename, fix database config
* blockchain: create `crate::open()`, `OpenTables::create_tables()`
* more compat fixes
* fix imports
* fix conflicts
* align cargo.toml
* docs
* fixes
* add `unused_crate_dependencies` lint, fix
* blockchain: add open table tests
2024-06-26 22:51:06 +01:00
hinto-janai
e405786a73
rpc: start cuprate-rpc-types
( #147 )
...
* rpc: add `monero-rpc-types`
* lib.rs: add lints
* add base files, deps
* fix macro generation, doc test
* add `strum`, add `misc` module
* document struct generation macro
* add `GetHeight`
* lib.rs: create re-export macro
* macro changes, add few more types
* docs
* `monero-rpc-types` -> `cuprate-rpc-types`
* fix modules
* specify commit in macro, add () type aliases
* macro docs, fixes
* add `Status::Other(String)`
* add TODO for `strum`
* Update rpc/types/Cargo.toml
Co-authored-by: Boog900 <boog900@tutanota.com>
* add `BinaryString`
* add `ResponseBase`
* add `CORE_RPC_*` constants
* fix status; use `CORE_RPC_*` constants
* cargo.toml: add `epee_encoding`
* rpc: add epee_encoding impl for `Status`
* macro: add epee_encoding for every type
* remove `strum`
* add response bases
* add `CORE_RPC_STATUS_UNKNOWN`
* add response/request bases for epee
* create `base` module
* use different type for macro example
* move base / root types around
* docs, status serde test
* status: use `Status::Unknown` for `epee_default_value`
* json: add missing fields to `GetBlockTemplateRequest`
not sure I missed these
cc73fe7116/src/rpc/core_rpc_server_commands_defs.h (L947-L950)
---------
Co-authored-by: Boog900 <boog900@tutanota.com>
2024-06-26 22:24:05 +01:00
5c08d1a0e2
Consensus: fix Rx VM initialization ( #190 )
...
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
* fix Rx VM initialization
* fix imports
* Apply suggestions from code review
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* use checked_sub
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-06-25 01:55:04 +01:00
hinto-janai
4b93dbec4c
workspace: enforce crate/directory naming scheme ( #164 )
...
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
Audit / audit (push) Has been cancelled
Deny / audit (push) Has been cancelled
* rename all directories and crates
* fix all `use`
* fix doc link
* `dandelion/` -> `dandelion-tower/`
* fix epee-encoding test
* fix `json-rpc`
* fix pruning
* crate import fixes
* fix leftover merge conflicts
* fix `epee-encoding`
2024-06-24 02:30:47 +01:00
519d871ccb
books: move in protocol book ( #169 )
...
* add protocol bool
* update url
* fix typos
* Cuprate's protocol book -> Monero
* Apply suggestions from code review
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* fix typo
* POW -> PoW
* revert weird line changes
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-06-24 01:23:39 +01:00
hinto-janai
fe1d5faac9
contributing: expand issue/PR sections, re-format ( #186 )
...
Audit / audit (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
Deny / audit (push) Has been cancelled
* contributing.md: expand tracking issue/pr section
* add tracking issue section
* re-format sections
* typos
* fix links
* add `.github/pull_request_template.md`
* add `Pull request title and description` section
* wording
2024-06-22 01:33:29 +01:00
10aac8cbb2
P2P: Block downloader ( #132 )
...
* impl async buffer
* clippy
* p2p changes
* clippy
* a few more docs
* init cuprate-p2p
* remove some unrelated code and add some docs
* start documenting client_pool.rs
* add more docs
* typo
* fix docs
* use JoinSet in connection maintainer
* small changes
* add peer sync state svc
* add broadcast svc
* add more docs
* add some tests
* add a test
* fix merge
* add another test
* unify PeerDisconnectFut and add more docs
* start network init
* add an inbound connection server
* remove crate doc for now
* fix address book docs
* fix leak in client pool
* correct comment
* fix merge + add some docs
* review comments
* init block downloader
* fix doc
* initial chain search
* add chain_tracker
* move block downloader to struct
* spawn task whe getting blocks
* check for free peers and handle batch response
* add test bin
* working block downloader
* dynamic batch sizes
* dandelion_tower -> dandelion-tower
* fix async-buffer builds
* check if incoming peers are banned
* add interface methods
* update docs
* use a JoinSet for background network tasks
* dynamic batch size changes
* Keep a longer of queue of blocks to get
* more checks on incoming data
* fix merge
* fix imports
* add more docs
* add some limits on messages
* keep peers that dont have the current need data
* fix clippy
* fix .lock
* fix stopping the block downloader
* clean up API and add more docs
* tracing + bug fixes
* fix panic
* doc changes
* remove test_init
* remove spammy log
* fix previous merge
* add a test
* fix test
* remove test unwrap
* order imports correctly
* clean up test
* add a timeout
* fix tests
* review fixes
* make `BlockDownloader` pub
* make `initial_chain_search` pub
* make `block_downloader` private
* Apply suggestions from code review
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
* split some sections into separate modules
* split chain requests
* sort imports
* check previous ID is correct
* fix typos
* Apply suggestions from code review
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
---------
Co-authored-by: hinto-janai <hinto.janai@protonmail.com>
2024-06-22 01:29:40 +01:00