Commit Graph

8739 Commits

Author SHA1 Message Date
skoupidi
2438bed158 script/research/blockchain-explorer: converted into a history providing daemon 2024-06-14 20:21:57 +03:00
skoupidi
1f4d72d3ad drk: restructer as a library 2024-06-14 15:05:10 +03:00
skoupidi
90b024f5fc darkfid/tests: use diff p2p ports on nodes of each test so they communicate with the ones expected when running concurently 2024-06-13 16:59:15 +03:00
kalm
cff9d0e7f5 validator/consensus: gas-based limit for unproposed transactions retrieval
Gas-based limit implementation to retrieve unproposed transactions. The limit is maintained by the constant 'GAS_LIMIT_UNPROPOSED_TXS', currently calculated as the product of the average total gas used and a gas limit multiplier equivalent to the existing TX_CAP value (i.e, 50).

The average total gas was obtained through analysis of empirical transaction test data, using a gas analysis tool.

The aim of this approach is to allow a gradual and controlled transition towards an optimal gas-based system. This minimizes potential adverse effects brought by changes to TX_CAP's implementation and provides the benefits of using gas to limit the number of txs received. This implementation will be fine-tuned until the discovery of the most efficient formula for determining the unproposed transactions' gas limit.

Tests have been added to verify the implementation's correctness by running transactions against it. To run the tests, run the following command from the bin/darkfid directory:

cargo test --release --bin darkfid tests::unproposed_txs
2024-06-13 05:27:05 -07:00
dasman
5399a54966 doc: bring back darkirc installation for android instructions 2024-06-13 14:14:14 +03:00
dasman
25c43d7187 remove nym page, and add a little note about its status 2024-06-13 14:06:30 +03:00
dasman
d040ef7b07 remove tag v0.4.1 from main README 2024-06-13 13:39:35 +03:00
dasman
cc75c50175 doc: add a note about rehash command in darkirc's private messages page 2024-06-13 13:38:11 +03:00
darkfi
a3db035ffa wallet: properly handle app cleanup (accidental cargo fmt so just check main.rs) 2024-06-13 11:46:07 +02:00
darkfi
6d295ab1ca wallet: migrate to using async slots/signals and zmq debug backend 2024-06-12 16:47:04 +02:00
darkfi
4b639e958a Cargo: remove crossbeam from dev-dependencies and comment out its benchmark 2024-06-12 13:58:54 +02:00
darkfi
927dfa7270 wallet: replace crossbeam::SkipMap<..> with Mutex<HashMap<...>> 2024-06-12 13:47:10 +02:00
darkfi
4a77e172c2 bench: crossbeam benchmark add reads 2024-06-12 13:38:27 +02:00
darkfi
9a76aa26e7 bench: crossbeam benchmark use the same group so we can directly compare lockless vs mutex 2024-06-12 13:03:07 +02:00
darkfi
ba07b8f89f bench: cargo fmt 2024-06-12 12:50:44 +02:00
darkfi
eecadc3482 bench: improve crossbeam benchmark to be more accurate 2024-06-12 12:46:30 +02:00
darkfi
2dc0b414bd bench: compare crossbeam SkipMap with Mutex<HashMap<...>> 2024-06-12 12:32:31 +02:00
skoupidi
37a864c89f darkfid/tests/harness: init an empty fork when generating node 2024-06-12 13:29:27 +03:00
darkfi
08b134d802 wallet: use pubsub to subscribe to events in main async draw() fn 2024-06-12 11:31:25 +02:00
darkfi
0d478f0721 wallet: begin making async version of gfx subsystem 2024-06-12 11:11:01 +02:00
dasman
9ad05642a3 example/p2pdebug: fix fromatting 2024-06-12 02:46:16 +03:00
dasman
823db436e4 replace last couple of ircd words 2024-06-12 02:40:37 +03:00
dasman
e87748f9c9 darkirc: rename pubkey recovery argument 2024-06-12 02:40:03 +03:00
dasman
8fcdd85673 doc: update darkirc private messages section 2024-06-12 02:29:09 +03:00
dasman
2bdb1b8cf9 remove irrelevant ircd scripts 2024-06-12 02:27:06 +03:00
skoupidi
c01d121a7a darkfid/task: generate an empty fork on consensus init, before any other task is triggered 2024-06-11 20:08:33 +03:00
dasman
ae3c67a7e0 replace ircd with darkirc throughout the codebase 2024-06-11 17:43:40 +03:00
dasman
130a29fa61 update main README to fix dakrirc link 2024-06-11 17:20:50 +03:00
dasman
8500bba446 doc: udpate and rename ircd to darkirc 2024-06-11 17:11:54 +03:00
darkfi
62c922c0ca doc: add section on security disclosure policy 2024-06-11 12:52:50 +02:00
draoi
c088ec5003 manual_session: reconnect when a manual connection disconnects 2024-06-10 17:22:18 +02:00
draoi
b0b192c3f2 system: rename Subscriber to Publisher + propagate change
We now subscribe to a Publisher which is clearer conceptually than
subscribing to a Subscriber.
2024-06-10 17:22:18 +02:00
foo
302d482475 money/client/transfer: Fix integer truncation issues when dividing for half-split
- Fix issue where `half` was calculated incorrectly for odd values of
  `value`
- Fix issue where sending a `value` of 1 and `half_split` of true would
  result in two empty value transfers

Note that this is only a client issue. The wasm back-end would cause the
invalid transfer to fail as the tx outputs from the client would not
match the inputs
2024-06-09 17:53:21 +03:00
foo
4eba00236d clippy: add suggested clippy lints to top-level Cargo.toml and enable
clippy linting at the workspace level for all crates

Configure all workspaces to use lints from the top-level Cargo.toml
  file
Add example lints that the project could configure to improve security
  and reliability.
Configure lints to warn level. Using deny level makes other binaries
fail to compile if even one of them has a failure.
No lints are added in this commit. Future changes can enable and fix
lints
2024-06-09 10:35:09 -04:00
dasman
49716b3e4c darkirc: fix getting NAMES list of history msgs 2024-06-08 03:12:58 +03:00
dasman
10c649f5dd darkirc+tau: add newly added args to config file 2024-06-08 03:10:29 +03:00
dasman
cfe9f49de2 dakirc+tau: do not create_dir_all on replay path if not needed 2024-06-08 03:03:24 +03:00
darkfi
09decc20a3 wallet: fix android crash(es) 2024-06-06 17:16:05 +02:00
darkfi
4ef00a37c0 wallet: add android build instructions and fix Cargo.toml paths 2024-06-06 14:41:01 +02:00
skoupidi
10a25005a7 darkfid: gracefully handle miner network dc 2024-06-06 15:30:02 +03:00
skoupidi
0892e3f58a darkfid: respect P2P configuration outbound connections timeout 2024-06-06 15:30:02 +03:00
darkfi
3b5ce35440 wallet: atrocious hackjob chatapp working on android with APKs 2024-06-06 13:38:38 +02:00
dasman
3bbbaa6308 make clippy happy again 2024-06-06 13:32:40 +03:00
parazyd
170654c423 darkirc: Use bcrypt-2b for server password encryption 2024-06-06 10:11:53 +02:00
lunar-mining
63a91dde41 net: remove potential race conditions
1. Shutting down all channels in p2p.stop() is redundant since they will
   be cleaned up by the session shutdown.
2. subscribe_stop().expect(..) could panic in the case that the node we
   are connecting to disconnects at this exact moment (triggering a
   `ChannelStopped` error).
2024-06-06 08:33:10 +02:00
dasman
897f495071 darkirc: fix duplicated name in config 2024-06-06 04:46:58 +03:00
dasman
94eac02ab8 darkirc: fix broken replay mode and datastore 2024-06-06 04:45:06 +03:00
dasman
37f85f49cd event_graph: dag replay logs and db to be configurable, also user should choose to run in replay mode or not 2024-06-06 04:42:47 +03:00
dasman
16826b2db2 darkirc: add IRC connection password 2024-06-06 04:07:32 +03:00
skoupidi
a755c30b75 contract/dao: renamed all day references to blockwindow 2024-06-05 16:33:38 +03:00