Commit Graph

3274 Commits

Author SHA1 Message Date
parazyd
41631701ac consensus: Compile fix. 2023-08-25 19:23:07 +02:00
parazyd
974ab22b96 net/seedsync_session: Use AtomicUsize for counting failed seed queries and return error. 2023-08-25 19:22:30 +02:00
parazyd
d7303b9784 net/seed: Count failed seeds and log error if all queries failed. 2023-08-25 19:10:57 +02:00
x
250c8ba2d0 bugfix: there's a type Arc<Weak<Foo>> when it should be Weak<Foo> 2023-08-25 19:07:53 +02:00
x
347f6da54e net/outbound: put p2p.remove_pending() in the correct place. 2023-08-25 18:45:49 +02:00
x
32c7cf0d63 net: fix the ever elusive bug that started our quest 2023-08-25 18:38:51 +02:00
x
2802225ddb remove nonsense code 2023-08-25 18:10:42 +02:00
x
cbee8ccace s/_addr/addr_/ 2023-08-25 17:14:07 +02:00
x
1e752bfb7e net: add peer discovery connection strategy 2023-08-25 17:05:21 +02:00
parazyd
9ed979454c chore: Add license headers to new .rs files. 2023-08-25 16:56:12 +02:00
x
324024b83e system/net: introduce LazyWeak which simplifies parent-child hierarchies 2023-08-25 15:17:58 +02:00
x
dce54b61c3 net/outbound_session: add PeerDiscovery process to OutboundSession. Slots and PeerDiscovery communicate through CondVar 2023-08-25 14:50:38 +02:00
x
61b35c2b79 system: add CondVar 2023-08-25 10:47:10 +02:00
parazyd
092b3bd0dd net/outbound_session: Randomize hosts list in fetch_address_with_lock. 2023-08-25 09:46:25 +02:00
Dastan-glitch
a2cc4a146f src/serial: add necessery imports for tests 2023-08-25 05:01:11 +03:00
Dastan-glitch
33c3bd2590 net: set localnet to false for test_store() as opposed to test_store_localnet() 2023-08-25 04:06:59 +03:00
Dastan-glitch
44602ff596 event_graph: added some info about methods 2023-08-25 02:58:43 +03:00
y
f6d1915556 zkas: fix index out of bounds panic
The decode() function panics when the input length is less than 10 bytes
in size due to direct magic-number indexing on the vector elements. This
check returns an error when the input is too small.
2023-08-24 18:38:03 +00:00
parazyd
2291a2bc90 lib: Minor clippy lints. 2023-08-24 15:33:41 +02:00
parazyd
2d0e3b0d89 lib: Clean up imports 2023-08-24 15:29:16 +02:00
parazyd
98703d361a lib: Add necessary traits around for async serial. 2023-08-24 14:27:03 +02:00
parazyd
75cb654068 serial: Introduce full async serialization support.
Unfortunately this duplicates the code, but it is beneficial for perf.
2023-08-24 14:27:03 +02:00
parazyd
dfdb4c0d5e darkfi-derive: Apply changes for internal Async{Encodable,Decodable} derive. 2023-08-24 14:27:03 +02:00
parazyd
e6fd1d5221 darkfi-derive-internal: Add support for Async{Encodable,Decodable} derive. 2023-08-24 14:27:02 +02:00
x
a53e84f5ea hosts: make quarantine_limit a configurable setting 2023-08-24 12:19:17 +02:00
x
61c269f776 net/outbound_session: start() doesnt return Err so remove error handling and result 2023-08-24 11:42:19 +02:00
x
2db408de14 p2p: greatly simplify & delet kod. p2p doesnt need a StoppableTask - the sessions themselves create their own StoppableTasks when calling start() and yield immediately. 2023-08-24 11:36:31 +02:00
x
21df1a2f52 add assert_err macro 2023-08-24 11:16:26 +02:00
x
d4ba515f7d net: remove p2p.run(), now we simply call p2p.start() and p2p.stop() 2023-08-24 11:00:58 +02:00
x
a2ae02ad9f net: reorganize code of outbound session into individual separated slots 2023-08-24 09:37:04 +02:00
x
2e1bc56371 net: remove redundant check, the prev line does p2p.exists(host). All sessions should add to this list through Session::perform_handshake_protocols() 2023-08-24 08:32:50 +02:00
x
68d51f794a net/hosts: rename load_*/get_* to fetch_*. We are doing an async get, so fetch more accurately conveys meaning here 2023-08-24 08:23:51 +02:00
parazyd
fe215e632c fuzz: Add zkas Lexer fuzzer. 2023-08-23 23:54:33 +02:00
parazyd
576a20e057 zkas: Propagate io::Result instead of aborting on errors. 2023-08-23 23:42:57 +02:00
parazyd
f5b34c56e6 contract/money: Enable forgotten test. 2023-08-23 19:50:14 +02:00
parazyd
cee481b0c3 chore: Update crate dependencies 2023-08-23 19:15:03 +02:00
Dastan-glitch
e67e7b25e2 rpc: fix close connection cleanly 2023-08-23 17:53:13 +03:00
y
ed53f896af chore: fix typos in comments and logs 2023-08-23 09:12:40 +00:00
greptile
970698f4a9 consensus: add unit test for bounds on f (#192)
* consensus: add unit test for bounds on f

Added test f_is_bounded to src/validator/consensus/pid.rs

Test by running:
cargo test --release --all-features f_is_bounded

* fix CI error (cargo fmt)

---------

Co-authored-by: y <y>
2023-08-23 09:12:13 +00:00
x
3b4103e40b net: change private p2p functions to pub(crate) 2023-08-23 10:45:59 +02:00
x
f203b77281 Revert "bugfix: get_log_config(), the log level is set in TermLogger::new(), not in get_log_config() which simply controls the formatting."
This reverts commit 39db8099d9.
2023-08-23 09:41:58 +02:00
x
39db8099d9 bugfix: get_log_config(), the log level is set in TermLogger::new(), not in get_log_config() which simply controls the formatting. 2023-08-23 09:25:06 +02:00
parazyd
ae6a2b7707 contract: Fix test compilation. 2023-08-22 20:25:29 +02:00
parazyd
9b4418931f zkas: Remove itertools dependency. 2023-08-22 20:22:58 +02:00
parazyd
2b3859e194 util/parse: Delete unused truncate() function. 2023-08-22 19:59:51 +02:00
parazyd
478bfa2a00 contract: Remove async-std dependencies. 2023-08-22 19:55:37 +02:00
parazyd
a02e3475f6 lib: Remove async-std dependency. 2023-08-22 19:55:37 +02:00
x
4c94fa251c add docstring for StoppableTask 2023-08-22 15:19:50 +02:00
parazyd
0f125fa2db net: Remove async-std dependency and prefer smol.
Also we now take the global executor and keep it around in P2p.
2023-08-22 15:07:48 +02:00
parazyd
557dfd0bb5 system: Implement async timeout helpers.
This is copied from async-std, under the MIT license.
2023-08-22 15:04:47 +02:00