Skip to content

Conversation

@jtimon
Copy link
Contributor

@jtimon jtimon commented Dec 5, 2016

CTxOut and CTransaction shouldn't depend on CFeeRate, which is something for policy checks and not consensus checks.
This replaces #7820

@jtimon
Copy link
Contributor Author

jtimon commented Dec 9, 2016

Mhmm, this fails on travis without qt but strangely it seems to work locally (ubuntu) all:

./configure --without-gui
./configure --disable-wallet --without-gui
./configure --disable-wallet

@dcousens
Copy link
Contributor

dcousens commented Dec 9, 2016

concept ACK

@sipa
Copy link
Member

sipa commented Dec 9, 2016

Concept ACK

@jtimon jtimon force-pushed the 0.13-consensus-dust-out-minimal branch 2 times, most recently from 53955e9 to b5ba7f4 Compare December 13, 2016 20:27
@jtimon
Copy link
Contributor Author

jtimon commented Dec 13, 2016

Rebased. Changing #include <stdlib.h> for #include <stdint.h> as suggested by ryanofsky_ on IRC solved the issue.

@jtimon
Copy link
Contributor Author

jtimon commented Jan 31, 2017

Rebased, @morcos mentioned the possibility of keep passing the CFeeRate to the new function, but after separating dustRelayFee, I'm not sure how he feels about it.

@laanwj
Copy link
Member

laanwj commented Feb 2, 2017

Concept ACK. This doesn't belong in transaction.h, or consensus code at all.

Copy link
Contributor

@dcousens dcousens left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

@NicolasDorier
Copy link
Contributor

Concept ACK. I would prefer that IsDust get an optional parameter to setup the dust FeeRate.

A reason to not use the same global everywhere is if we decide to have a Dust FeeRate higher at the wallet level. I detailed the reason at #7677

@jtimon jtimon force-pushed the 0.13-consensus-dust-out-minimal branch from 976261f to 9e7f477 Compare February 3, 2017 05:17
@jtimon
Copy link
Contributor Author

jtimon commented Feb 3, 2017

Changed to maintain CFeeRate param in GetDustThreshold/IsDust.
And rebased without need, why not?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should change to fDust =| IsDust(txout, ::dustRelayFee); to maintain the logic.

@jtimon jtimon force-pushed the 0.13-consensus-dust-out-minimal branch from 9e7f477 to 4e124f8 Compare February 9, 2017 21:30
@jtimon
Copy link
Contributor Author

jtimon commented Feb 9, 2017

Fixed @NicolasDorier 's great catch.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not necessary, I assume? Kinda defeats the purpose :)

@morcos
Copy link
Contributor

morcos commented Feb 10, 2017

@jtimon what do you think about removing the factor of 3 in the formula, and then just increasing the dustRelayTxFee in the code to 3000 sat/KB. Seems unnecessarily complicated as is.

@jtimon
Copy link
Contributor Author

jtimon commented Feb 11, 2017

I think your suggestion makes sense, but I would really try to avoid scope creep here. I've been wanting to move this for very long...(see #5114 ).
Seems like a simple change to do afterwards.

@jtimon jtimon force-pushed the 0.13-consensus-dust-out-minimal branch from 4e124f8 to 45ba355 Compare February 11, 2017 02:53
@jtimon
Copy link
Contributor Author

jtimon commented Feb 11, 2017

Fixed @theuni 's nit.

I was going to add @morcos ' suggestion too, but I'm not sure how to rephrase this:

"Fee rate (in %s/kB) used to defined dust, the value of an output such that it will cost about 1/3 of its value in fees at this fee rate to spend it." (init.cpp)
The comment on DUST_RELAY_TX_FEE delcaration (policy/policy.h) would probably need some modifications too.

@jtimon jtimon force-pushed the 0.13-consensus-dust-out-minimal branch from 45ba355 to c32f28b Compare April 4, 2017 16:09
@jtimon
Copy link
Contributor Author

jtimon commented Apr 4, 2017

Needed rebase

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Auto-nit: s/2015/2017/
also maybe remove the line with satoshi?

@jtimon jtimon force-pushed the 0.13-consensus-dust-out-minimal branch from c32f28b to cb9d875 Compare April 5, 2017 23:08
@jtimon
Copy link
Contributor Author

jtimon commented Apr 5, 2017

Rebased to make travis run again because

E: Failed to fetch http://us-central1.gce.archive.ubuntu.com/ubuntu/pool/universe/w/wine1.6/wine1.6_1.6.2-0ubuntu4_amd64.deb  503  Service Unavailable [IP: 23.236.60.84 80]
...

laanwj added a commit that referenced this pull request May 9, 2017
381a46e Consensus: Policy: MOVEONLY: Move CFeeRate out of the consensus module (Jorge Timón)
330bb5a Consensus: Minimal way to move dust out of consensus (Jorge Timón)

Tree-SHA512: 19a2ea8169afd5a9d3f940d8974e34cfaead153e3ff3068ac82fccdb8694d19d9b45938904ec9e8cd095bd5ca3a0080364da29372f6aaf56b11a6c2ccd6c7a4d
@jtimon jtimon deleted the 0.13-consensus-dust-out-minimal branch May 30, 2017 18:32
markblundeberg pushed a commit to markblundeberg/bitcoin-abc that referenced this pull request May 23, 2019
Summary:
Backport of Core PR9278
bitcoin/bitcoin#9279

Test Plan:
  make check
  test_runner.py

Reviewers: deadalnix, jasonbcox, Fabien, markblundeberg, O1 Bitcoin ABC, #bitcoin_abc

Reviewed By: Fabien, O1 Bitcoin ABC, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D3039
markblundeberg pushed a commit to markblundeberg/bitcoin-abc that referenced this pull request May 23, 2019
Summary:
Backport of Core PR9279
bitcoin/bitcoin#9279

Test Plan:
  make check
  test_runner.py

Reviewers: deadalnix, jasonbcox, Fabien, markblundeberg, O1 Bitcoin ABC, #bitcoin_abc

Reviewed By: Fabien, O1 Bitcoin ABC, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D3039
jonspock pushed a commit to devaultcrypto/devault that referenced this pull request Jun 13, 2019
Summary:
Backport of Core PR9278
bitcoin/bitcoin#9279

Test Plan:
  make check
  test_runner.py

Reviewers: deadalnix, jasonbcox, Fabien, markblundeberg, O1 Bitcoin ABC, #bitcoin_abc

Reviewed By: Fabien, O1 Bitcoin ABC, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D3039
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Jun 26, 2019
381a46e Consensus: Policy: MOVEONLY: Move CFeeRate out of the consensus module (Jorge Timón)
330bb5a Consensus: Minimal way to move dust out of consensus (Jorge Timón)

Tree-SHA512: 19a2ea8169afd5a9d3f940d8974e34cfaead153e3ff3068ac82fccdb8694d19d9b45938904ec9e8cd095bd5ca3a0080364da29372f6aaf56b11a6c2ccd6c7a4d
jtoomim pushed a commit to jtoomim/bitcoin-abc that referenced this pull request Jun 29, 2019
Summary:
Backport of Core PR9278
bitcoin/bitcoin#9279

Test Plan:
  make check
  test_runner.py

Reviewers: deadalnix, jasonbcox, Fabien, markblundeberg, O1 Bitcoin ABC, #bitcoin_abc

Reviewed By: Fabien, O1 Bitcoin ABC, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D3039
jtoomim pushed a commit to jtoomim/bitcoin-abc that referenced this pull request Jun 29, 2019
Summary:
Backport of Core PR9279
bitcoin/bitcoin#9279

Test Plan:
  make check
  test_runner.py

Reviewers: deadalnix, jasonbcox, Fabien, markblundeberg, O1 Bitcoin ABC, #bitcoin_abc

Reviewed By: Fabien, O1 Bitcoin ABC, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D3039
random-zebra added a commit to PIVX-Project/PIVX that referenced this pull request Nov 6, 2020
874096e [MOVEONLY] Move CFeeRate out of the consensus module (random-zebra)

Pull request description:

  After #1950, this PR completes the backport of bitcoin#9279 to move CFeeRate out of libconsensus.

  > CTxOut and CTransaction shouldn't depend on CFeeRate, which is something for policy checks and not consensus checks.

ACKs for top commit:
  furszy:
    all good now, utACK 874096e
  Fuzzbawls:
    utACK 874096e

Tree-SHA512: e5c33d7e26003a1c4acb5159c24be5ac0209fe9875b7b7d430cd8927c2174ea4727a8728a065dcf0bf8be4389b8f90fdfab227face458c014cf409385a106baa
@bitcoin bitcoin locked as resolved and limited conversation to collaborators Sep 8, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

10 participants