Skip to content

sync beta [0.7.2]#542

Merged
ca333 merged 116 commits intobetafrom
dev
Jun 12, 2022
Merged

sync beta [0.7.2]#542
ca333 merged 116 commits intobetafrom
dev

Conversation

@Alrighttt
Copy link
Copy Markdown

No description provided.

DeckerSU added 12 commits May 27, 2022 19:33
also possible optimize of loop iterating txes, in case of height == 0,
don't need to call komodo_block2height for each tx, call it once before
iterating loop is enough.

# Conflicts:
#	src/main.cpp
instead of block.nTime (pblock->nTime). This should prevent existance of
txes, which are already added in mempool, but never will be added to a
block (skipped on create blocktemplate stage), bcz of MTP too far away
from block creation time in case of big gaps between blocks.

# Conflicts:
#	src/miner.cpp
… error

Before debug.log in case of komodo_validate_interest failed was like:

2022-04-29 03:14:33 AcceptToMemoryPool komodo_validate_interest failure
2022-04-29 03:14:33 ERROR: AcceptToMemoryPool: komodo_validate_interest failed

We removed 1st message and added txid to 2nd.

# Conflicts:
#	src/main.cpp
We don't need to call pindexPrev->GetMedianTimePast() on every mempool
tx iteration, it's calculated before in nMedianTimePast. Also we don't
need params variable, as we already have consensusParams defined above.

# Conflicts:
#	src/miner.cpp
- re-format, remove useless comments and dead code.
- remove unused variables.
- remove set<CBitcoinAddress> setAddress and conditions containing
  it, bcz setAddress.size() is always 0, so these paths in the code
  are dead.
- get rid of most pointer operations, instead of memcmp passed notarypub33,
  we construct targetP2PKScript and compare it with scripts from
  available utxos.
- don't allow to spend unconfirmed 10k sat. utxos, bcz we don't ensure that they would be included in the same block.

# Conflicts:
#	src/wallet/rpcwallet.cpp
to pass two params in a function earlier we used a (void **) to
handle pointers on these 2 params in "array". also there was "hidden"
parameter, this pointer itself, if pointer == 0 -> it before HF time,
if pointer !=0 -> after HF time, and we should extract two params from
array of passed pointers. of course it can be replaced with tuple, or
boost::optional with tuple "inside", but much more simple way is to
pass params (CScript and nLockTime) in komodo_notaryvin same way as they
exits and assume that if passed CScript().size() == 0, it before HF
and if size() > 0 - it after HF.

# Conflicts:
#	src/miner.cpp
"Backport" of bitcoin/bitcoin#10534 to our
codebase.

TODO: consider to use latest prevector implementation from Bitcoin upstream.
@ca333 ca333 changed the title Dev sync beta [0.7.2] Jun 12, 2022
@ca333 ca333 merged commit fb4b355 into beta Jun 12, 2022
who-biz pushed a commit to who-biz/komodo that referenced this pull request Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants