Skip to content

Conversation

@TheBlueMatt
Copy link
Contributor

This fixes #10981 in my preferred way.

@laanwj
Copy link
Member

laanwj commented Aug 5, 2017

utACK

@laanwj laanwj added this to the 0.15.0 milestone Aug 5, 2017
@laanwj laanwj added the Wallet label Aug 5, 2017
@sipa
Copy link
Member

sipa commented Aug 5, 2017

utACK 48ff1822a007195640299f728d75b52e6d4a22a6

@promag
Copy link
Contributor

promag commented Aug 6, 2017

Even though resendwallettransactions is for testing purpose, having an empty response indicates that there are no unconfirmed transactions, which can be incorrect. IMO it should return an error like, for instance, RPC_INVALID_REQUEST.

@TheBlueMatt
Copy link
Contributor Author

@promag seems reasonable, I added a commit to do so.

Copy link
Contributor

@promag promag left a comment

Choose a reason for hiding this comment

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

Concept ACK modulus comments.

Copy link
Contributor

Choose a reason for hiding this comment

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

Nit, curly braces.

Copy link
Contributor

Choose a reason for hiding this comment

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

Remove and let it hit assert.

Copy link
Contributor

Choose a reason for hiding this comment

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

In the help you reference the app arg, but not in the error message. Make them consistent?

@TheBlueMatt
Copy link
Contributor Author

Fixed issues and squashed.

@TheBlueMatt TheBlueMatt force-pushed the 2018-08-walletbroadcast-assert branch from b42d651 to 01699fb Compare August 7, 2017 01:41
@laanwj laanwj merged commit 01699fb into bitcoin:master Aug 7, 2017
laanwj added a commit that referenced this pull request Aug 7, 2017
…roadcast=0

01699fb Fix resendwallettransactions assert failure if -walletbroadcast=0 (Matt Corallo)

Pull request description:

  This fixes #10981 in my preferred way.

Tree-SHA512: 2e43d3ac78d13c5d59db23a82c76c722cc3344767a8237617080e489296d27a98bb1b3bd469b2c9b289b57a9da3709c90448d7a23bcc2e1dfb791c4fd16be015
@dougstrong77
Copy link

Plz send me some where to learn this im confused and screwing up everything

@jnewbery
Copy link
Contributor

jnewbery commented Aug 7, 2017

Post-merge comment: application-level errors should not use RPC_INVALID_REQUEST. Fixed in #11002.

laanwj added a commit that referenced this pull request Aug 8, 2017
…nsaction

055d95f [wallet] return correct error code from resendwallettransaction (John Newbery)

Pull request description:

  New code in #10995 uses `RPC_INVALID_REQUEST`. According to the comment in rpc/protocol.h:
  ```
  // RPC_INVALID_REQUEST is internally mapped to HTTP_BAD_REQUEST (400).
  // It should not be used for application-layer errors.
  ```
  Change the returned error code to `RPC_WALLET_ERROR`

  #11000 will need to be updated to test for the correct error code.

Tree-SHA512: 0201b3a2091adf17ad301825da5bd29f0ea7e284b5394cbef80483fc293a558acc849f74a0780bb8501acab324fc722e41ae049cffec7afb76884e26df4b809e
maflcko pushed a commit that referenced this pull request Aug 12, 2017
bdf607e test: Add resendwallettransactions functional tests (João Barbosa)

Pull request description:

  Adds functional tests to cover the behaviour introduced in #10995.

Tree-SHA512: 3be337cbe51edab2cc0eb9ecfa68d00cd3c3a00aef0672cd841706802726c9cd4138626a8f209c3d9fbd207ce332daa062f270e4c94c1c2398bfc475e36423f6
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Aug 2, 2019
bdf607e test: Add resendwallettransactions functional tests (João Barbosa)

Pull request description:

  Adds functional tests to cover the behaviour introduced in bitcoin#10995.

Tree-SHA512: 3be337cbe51edab2cc0eb9ecfa68d00cd3c3a00aef0672cd841706802726c9cd4138626a8f209c3d9fbd207ce332daa062f270e4c94c1c2398bfc475e36423f6
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Aug 5, 2019
…walletbroadcast=0

01699fb Fix resendwallettransactions assert failure if -walletbroadcast=0 (Matt Corallo)

Pull request description:

  This fixes bitcoin#10981 in my preferred way.

Tree-SHA512: 2e43d3ac78d13c5d59db23a82c76c722cc3344767a8237617080e489296d27a98bb1b3bd469b2c9b289b57a9da3709c90448d7a23bcc2e1dfb791c4fd16be015
PastaPastaPasta pushed a commit to PastaPastaPasta/dash that referenced this pull request Aug 5, 2019
…llettransaction

055d95f [wallet] return correct error code from resendwallettransaction (John Newbery)

Pull request description:

  New code in bitcoin#10995 uses `RPC_INVALID_REQUEST`. According to the comment in rpc/protocol.h:
  ```
  // RPC_INVALID_REQUEST is internally mapped to HTTP_BAD_REQUEST (400).
  // It should not be used for application-layer errors.
  ```
  Change the returned error code to `RPC_WALLET_ERROR`

  bitcoin#11000 will need to be updated to test for the correct error code.

Tree-SHA512: 0201b3a2091adf17ad301825da5bd29f0ea7e284b5394cbef80483fc293a558acc849f74a0780bb8501acab324fc722e41ae049cffec7afb76884e26df4b809e
@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.

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

resendwallettransactions asserts if walletbroadcast=0

6 participants