Antioch Peverell
29cffe9b3c
verify_cut_through and test coverage ( #3424 )
...
* fix inconsistent verify_cut_through() logic
* add test coverage for chain::process_block() and cut_through logic
* fix comment
2020-08-18 20:09:54 +01:00
Nym Seddon
6a012d7e5b
Add TransactionPool fuzz driver ( #3396 )
...
Add fuzz driver for fuzzing adding transactions to the main and stem
TransactionPool
Co-authored-by: Nym Seddon <unseddd@shh.xyz>
2020-08-17 14:05:25 -04:00
Quentin Le Sceller
a038687d20
Fix #3380 Broken API Links ( #3381 )
2020-08-17 13:28:38 -04:00
Antioch Peverell
efece9e0c7
use sync pmmr for building locator ( #3397 )
2020-08-17 13:21:54 -04:00
Antioch Peverell
599bf22cfc
Simplify api commits ( #3423 )
...
* simplify api with unspent by commitment
* fix chain tests
2020-08-17 13:19:29 -04:00
Quentin Le Sceller
d1b90f89a0
Update dockerfile with rust 1.45 and Debian Buster ( #3426 )
2020-08-17 12:11:27 -04:00
draz3nv
110deff702
[Docs] Revision to intro page ( #3281 )
...
* Update intro.md
Co-authored-by: Quentin Le Sceller <q.lesceller@gmail.com>
2020-08-11 17:43:06 -04:00
John Tromp
9c517db3c3
add test cases for C32 and C33 solutions ( #3422 )
2020-08-10 11:05:13 -04:00
Antioch Peverell
34adaf797e
orphan check needs to handle fast sync "edge case" ( #3418 )
2020-08-08 11:21:38 +01:00
Antioch Peverell
4732a0b62b
convert tx for v2 compatibility on way into stempool/txpool ( #3412 )
...
cleanup passing extra_tx around
use output identifiers when converting tx to v2
2020-08-02 13:26:28 +01:00
Nym Seddon
6a12155738
Expose max_tx_weight
API ( #3407 )
...
Add API for getting max transaction weight
Co-authored-by: Nym Seddon <unseddd@shh.xyz>
2020-08-02 08:50:59 +01:00
Antioch Peverell
880f9adcd3
use AsRef in cut_through for flexibility ( #3411 )
...
and use fold() to get len of inputs, outputs, kernels
2020-08-01 15:19:17 +01:00
Antioch Peverell
04c8713d83
refactor apply_inputs and support converting block for v2 compatibility ( #3409 )
...
* wip
* convert incoming block to v2, rework orphan and duplicate check earlier than conversion
* cleanup process_block_single
* cleanup block conversion
* cleanup
* leverage utxo_view when applying block inputs
2020-07-31 14:36:20 +01:00
Antioch Peverell
70c637fe4f
make cut_through significantly more useful by returning both cut-through and non-cut-through elements ( #3410 )
...
split the slices internally rather than simply taking sub-slices
2020-07-30 15:29:20 +01:00
Antioch Peverell
83b269961a
introduce Inputs enum variants for future commit only support ( #3406 )
2020-07-28 21:21:57 +01:00
Antioch Peverell
b43666af80
cleanup inputs_mut, outputs_mut, kernels_mut fns ( #3405 )
2020-07-27 11:54:43 +01:00
Antioch Peverell
80841f16d2
pass slices around and not refs to vecs ( #3404 )
...
* pass slices around and not refs to vecs
* use slice.swap()
* use inputs() not body.inputs
2020-07-27 11:07:18 +01:00
Antioch Peverell
105f50b26b
cleanup unused macros and error ( #3367 )
2020-07-27 11:06:16 +01:00
Antioch Peverell
ec3ea9c3ff
pass ref to chain around ( #3401 )
2020-07-27 11:05:12 +01:00
Antioch Peverell
3c06672e9b
include height even for spent outputs in get_outputs api ( #3400 )
2020-07-22 08:32:09 -04:00
Nym Seddon
d78980c4c4
P2P replace DNS panic with map_err ( #3383 )
...
Replace panic on DNS resolution error with map_err to bubble
up error to the caller
Co-authored-by: Nym Seddon <unseddd@shh.xyz>
2020-07-17 13:44:43 +01:00
Antioch Peverell
824c51a346
bump version to 4.1.0 on master (4.0.1 on 4.0.x branch) ( #3390 )
2020-07-13 12:16:43 +01:00
Antioch Peverell
84ad59c5be
more robust handling of min_height and max_height in get_kernel_height() ( #3387 )
...
* more robust handling of min_height and max_height in get_kernel_height()
* cleanup
2020-07-13 11:31:52 +01:00
Antioch Peverell
32253194b5
log reorg (and fork) depth correctly ( #3376 )
...
* log reorg (and fork) depth correctly
depth should be based on "fork point" not prev head
* correct depth for fork/reorg (0 for alternate head etc.)
2020-07-08 09:02:28 +01:00
Antioch Peverell
30db9c410e
bump master to 4.0.1-alpha.1 to differentiate from 4.0.0 official tagged build ( #3374 )
2020-07-02 15:51:11 +01:00
Yeastplume
7abe9fcb39
Versioning for 4.0.0 release ( #3373 )
2020-07-02 10:29:10 +01:00
Yeastplume
098d25e569
Version bump for 4.0.0-rc.1 ( #3366 )
2020-06-26 13:10:42 +01:00
John Tromp
238522a9fb
add CuckooParams::node_mask, obsolete EdgeType and sipnode shift arg ( #3365 )
2020-06-26 12:13:25 +01:00
Nym Seddon
39ca5d1c11
Store: error handling for file errors ( #3364 )
...
Use existing error handling plumbing for Store file creation errors
Co-authored-by: Nym Seddon <unseddd@shh.xyz>
2020-06-25 10:20:26 +01:00
Antioch Peverell
20b4500625
make sure header PMMR is init correctly based on header_head from db ( #3362 )
...
* make sure header PMMR is init correctly based on header_head from db
* fix to ensure header PMMR is consistent with header_head in db on chain init
* change order of operations - validate header earlier
and avoid applying header to header PMMR before validation
as this potentially leaves the PMMR in a tricky state to rewind from
2020-06-22 10:04:09 -04:00
Antioch Peverell
d3598e25eb
credit where credit is due ( #3356 )
2020-06-16 18:41:09 +01:00
Antioch Peverell
55a929e214
cleanup old unused code ( #3355 )
2020-06-15 15:05:47 +01:00
Antioch Peverell
dd88d28a7a
bump version to 4.0.0-beta.2 ( #3351 )
2020-06-12 14:08:12 +01:00
Quentin Le Sceller
0cb1a352d3
Remove wallet from CLI ( #3347 )
2020-06-12 08:39:53 -04:00
Quentin Le Sceller
2fe21c5ceb
Cargo update ( #3350 )
2020-06-11 10:01:24 -04:00
Antioch Peverell
ce141bee29
chain stats should use head.hash() ( #3348 )
2020-06-10 22:41:50 +01:00
Antioch Peverell
2223d9f7d7
migrate to V2 Cargo.lock format ( #3346 )
...
* migrate to V2 Cargo.lock format
* arrays on multiple lines
2020-06-10 22:21:38 +01:00
Antioch Peverell
6757a3040d
this test was jamming up in azure CI ( #3349 )
...
* this test was jamming up in azure CI
* peer handshake test requires global chain type
2020-06-10 21:56:28 +01:00
Quentin Le Sceller
e7f04240fb
Fix compiler warnig ( #3345 )
2020-06-10 12:41:44 -04:00
Antioch Peverell
20e5c1910b
NRD rules and "recent" kernel pos index ( #3302 )
...
* variants for output_pos linked list entries (head/tail/middle/unique)
next and prev and Vec<u8> lmdb keys
* get_pos on enum
* break list and list entries out into separate enums
* track output features in the new output_pos index, so we can determine coinbase maturity
* push entry impl for none and unique
* some test coverage for output_pos_list
* commit
* wip - FooListEntry
* use instance of the index
* linked list of output_pos and commit_pos both now supported
* linked_list
* cleanup and rename
* rename
* peek_pos
* push some, peek some, pop some
* cleanup
* commit pos
cleanup
* split list and entry out into separate db prefixes
* cleanup and add placeholder for pop_back
* pop_pos_back (for popping off the back of the linked list)
test coverage for pop_pos_back
* wip
* placeholder for prune via a trait
pos must always increase in the index
* rewind kernel_pos_idx when calling rewind_single_block
* RewindableListIndex with rewind support.
* test coverage for rewindable list index
* test coverage for rewind back to 0
* rewind past end of list
* add tests for kernel_pos_idx with multiple commits
* commit
* cleanup
* hook NRD relative lock height validation into block processing and tx validation
* cleanup
* set local chain type for kernel_idx tests
* add test coverage for NRD rules in block processing
* NRD test coverage and cleanup
* NRD relative height 1 test
* test coverage for NRD kernels in block processing
* cleanup
* start of test coverage for txpool NRD kernel rules
* wip
* rework pool tests to use real chain (was mock chain) to better reflect reality (tx/block validation rules etc.)
* cleanup
* cleanup pruneable trait for kernel pos index
* add clear() to kernel_pos idx and test coverage
* hook kernel_pos rebuild into node startup, compaction and fast sync
* verify full NRD history on fast sync
* return early if nrd disabled
* fix header sync issue
2020-06-10 16:38:29 +01:00
Antioch Peverell
b98e5e06a6
fix race condition ( #3344 )
2020-06-10 13:56:33 +01:00
Quentin Le Sceller
093c500fed
Cargo Update ( #3338 )
2020-06-08 17:15:32 -04:00
John Tromp
e28e02ecd4
simplify by avoiding unnecessary conversions ( #3343 )
2020-06-08 17:04:06 -04:00
Boqin Qin
992d450e0a
servers, util: fix deadlock caused by conflicting lock order ( #3340 )
2020-06-08 16:59:17 -04:00
Antioch Peverell
c54568e69f
Rework pool tests to use real chain (was mock chain) ( #3342 )
...
* rework pool tests to use real chain (was mock chain) to better reflect reality (tx/block validation rules etc.)
* cleanup
2020-06-07 09:26:08 +01:00
Yeastplume
c7c9a32b9b
4.0.0-beta.1 Version Bump ( #3339 )
2020-06-04 14:52:26 +01:00
John Tromp
f4295917a0
header version 4 accompanied by new AR PoW ( #3334 )
2020-06-04 09:05:56 -04:00
Boqin Qin
450d235358
servers: fix possible deadlock ( #3337 )
2020-06-03 13:34:44 +02:00
Antioch Peverell
e7d2c71ca6
display chain type on tui title bar ( #3336 )
2020-05-29 09:18:00 -04:00
Antioch Peverell
5b825fbf0d
check_known now takes total_difficulty into consideration ( #3298 )
...
* check_known now takes total_difficulty into consideration
* update based on feedback
2020-05-29 10:21:12 +01:00