New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix: Use testnet RequireStandard for -acceptnonstdtxn default #11026

Merged
merged 1 commit into from Aug 22, 2017

Conversation

Projects
None yet
7 participants
@luke-jr
Member

luke-jr commented Aug 10, 2017

Fixes a bug introduced in #8855

-acceptnonstdtxn is a valid option only for testnet/regtest (in Core), and the help message reflects that. Currently, however, it is buggy in two ways:

  1. It uses mainnet to get the default value, which doesn't make sense since the option is never available for mainnet, and the only time the option is available, is when the default is the opposite.
  2. It uses the value of "require standard" directly as the default for "accept non-standard transactions", but these concepts are opposites: a negation must be performed to transform one to the other.

Note the combination of these bugs results in the correct boolean output, but the logic to get there is completely wrong.

@MarcoFalke MarcoFalke added the Docs label Aug 10, 2017

@sdaftuar

This comment has been minimized.

Show comment
Hide comment
@sdaftuar

sdaftuar Aug 11, 2017

Member

utACK

Member

sdaftuar commented Aug 11, 2017

utACK

@sipa

This comment has been minimized.

Show comment
Hide comment
@sipa

sipa Aug 12, 2017

Member

Care to elaborate a bit?

Member

sipa commented Aug 12, 2017

Care to elaborate a bit?

@luke-jr

This comment has been minimized.

Show comment
Hide comment
@luke-jr

luke-jr Aug 13, 2017

Member

-acceptnonstdtxn is a valid option only for testnet/regtest (in Core), and the help message reflects that. Currently, however, it is buggy in two ways:

  1. It uses mainnet to get the default value, which doesn't make sense since the option is never available for mainnet, and the only time the option is available, is when the default is the opposite.
  2. It uses the value of "require standard" directly as the default for "accept non-standard transactions", but these concepts are opposites: a negation must be performed to transform one to the other.

Note the combination of these bugs results in the correct boolean output, but the logic to get there is completely wrong.

Member

luke-jr commented Aug 13, 2017

-acceptnonstdtxn is a valid option only for testnet/regtest (in Core), and the help message reflects that. Currently, however, it is buggy in two ways:

  1. It uses mainnet to get the default value, which doesn't make sense since the option is never available for mainnet, and the only time the option is available, is when the default is the opposite.
  2. It uses the value of "require standard" directly as the default for "accept non-standard transactions", but these concepts are opposites: a negation must be performed to transform one to the other.

Note the combination of these bugs results in the correct boolean output, but the logic to get there is completely wrong.

@achow101

This comment has been minimized.

Show comment
Hide comment
@achow101
Member

achow101 commented Aug 18, 2017

utACK 4aa2508

@MeshCollider

This comment has been minimized.

Show comment
Hide comment
@MeshCollider
Member

MeshCollider commented Aug 19, 2017

utACK 4aa2508

@laanwj laanwj merged commit 4aa2508 into bitcoin:master Aug 22, 2017

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details

laanwj added a commit that referenced this pull request Aug 22, 2017

Merge #11026: Bugfix: Use testnet RequireStandard for -acceptnonstdtx…
…n default

4aa2508 Bugfix: Use testnet RequireStandard for -acceptnonstdtxn default (Luke Dashjr)

Pull request description:

  Fixes a bug introduced in #8855

  `-acceptnonstdtxn` is a valid option only for testnet/regtest (in Core), and the help message reflects that. Currently, however, it is buggy in two ways:

  1. It uses mainnet to get the default value, which doesn't make sense since the option is never available for mainnet, and the only time the option is available, is when the default is the opposite.
  2. It uses the value of "require standard" directly as the default for "accept non-standard transactions", but these concepts are opposites: a negation must be performed to transform one to the other.

  Note the combination of these bugs results in the correct boolean output, but the logic to get there is completely wrong.

Tree-SHA512: 06ce513f59ba31f7ab4b6422a08a17bb37a5652dea4c38a4bbefedd5e2752d17bfccc32a4b0508068fa4783e316bff00a821ef18a24b1a2bb02859995d188fdc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment