Skip to content

Conversation

@kallewoof
Copy link
Contributor

See #10300.

@jnewbery
Copy link
Contributor

jnewbery commented May 1, 2017

utACK 0300d5e.

Can you add a test to exercise the new functionality? Perhaps add some calls to getrawmempool with specified txids to the mempool_reorg test. Around here:

assert_equal(set(self.nodes[0].getrawmempool()), {spend_101_id, spend_102_1_id, timelock_tx_id})

@sipa
Copy link
Member

sipa commented May 1, 2017

I believe this functionality already exists as getmempoolentry.

@kallewoof
Copy link
Contributor Author

@sipa Indeed, I had completely missed that one. I'm surprised there's a whole command for it, personally. (And it doesn't seem to be well known as several people (me, issue author, ..) did not realize it, so it may be an idea to mention it in getrawmempool help.)

@paveljanik
Copy link
Contributor

Thinking a bit more about it, gettransaction should be generalised to include not only in-wallet transactions, but also in-mempool txs. as we have in-wallet, in-blockchain/non-wallet and in-mempool txs (why entries?). But this is backward incompatible change in the API.

@sipa
Copy link
Member

sipa commented May 4, 2017

@paveljanik We have getrawtransaction for that, which can query for mempool transactions (and without -txindex, that's pretty much the only thing it is useful for).

I disagree that gettransaction should be extended. Despite its name, gettransaction actually does not return information about a transaction, but is a wallet RPC that returns information about a ledger entry (i.e., the effects a transaction has on your personal balance).

@kallewoof kallewoof deleted the getrawmempool-include-txid branch May 9, 2017 00:13
@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.

5 participants