Skip to content

Conversation

@promag
Copy link
Contributor

@promag promag commented Apr 3, 2019

Closes #15702.

@promag
Copy link
Contributor Author

promag commented Apr 3, 2019

Similar to #15596.

@promag
Copy link
Contributor Author

promag commented Apr 3, 2019

@MarcoFalke is this what you mean in #15702?

Copy link
Member

Choose a reason for hiding this comment

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

This shouldn't count conflicts

Copy link
Contributor Author

Choose a reason for hiding this comment

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

IsTrusted already checks GetDepthInMainChain > 0, isn't it enough?

@DrahtBot
Copy link
Contributor

DrahtBot commented Apr 3, 2019

The following sections might be updated with supplementary metadata relevant to reviewers and maintainers.

Conflicts

Reviewers, this pull request conflicts with the following ones:

If you consider this pull request important, please also help to review the conflicting pull requests. Ideally, start with the one that should be merged first.

@promag promag marked this pull request as ready for review April 7, 2019 16:18
@luke-jr
Copy link
Member

luke-jr commented Apr 8, 2019

This should throw an exception, not simply be ignored...

@promag promag force-pushed the 2019-04-drop-getbalance-minconf branch from 7b12646 to 8676e7a Compare April 8, 2019 12:43
@promag
Copy link
Contributor Author

promag commented Apr 8, 2019

@luke-jr I'm doing the same as #15596. Why throw an error?

@luke-jr
Copy link
Member

luke-jr commented Apr 8, 2019

Because if I specify minconf=10, I expect the value with received transactions less than 10 blocks deep to be excluded. Returning a wrong answer is not a reasonable API change.

#15596 should probably be throwing an error too.

@promag
Copy link
Contributor Author

promag commented Apr 8, 2019

@luke-jr how about renaming to min_conf_theirs=10? That wouldn't cause confusion and allows to take into account change (or send to self) outputs with 1 confirmation.

@maflcko
Copy link
Member

maflcko commented Apr 8, 2019

@luke-jr I'm doing the same as #15596. Why throw an error?

#15596 has always ignored the minconf parameter, getbalance did not. So I think an error is fine here.

@laanwj
Copy link
Member

laanwj commented Apr 10, 2019

This should throw an exception, not simply be ignored...

Yes, error is definitely better. Programs ignoring arguments can be incredibly frustrating.

@promag
Copy link
Contributor Author

promag commented Apr 10, 2019

Then when should it throw an error? minconf > 0?

@luke-jr
Copy link
Member

luke-jr commented Apr 18, 2019

minconf != 0

@promag promag force-pushed the 2019-04-drop-getbalance-minconf branch 2 times, most recently from 797e058 to fbad2ee Compare April 22, 2019 00:13
@promag promag changed the title rpc: Ignore minconf parameter in getbalance rpc: Raise error in getbalance if minconf is not zero Apr 22, 2019
@promag
Copy link
Contributor Author

promag commented Apr 22, 2019

Now raising error.

@promag promag force-pushed the 2019-04-drop-getbalance-minconf branch from fbad2ee to f907ed2 Compare May 5, 2019 23:57
@promag
Copy link
Contributor Author

promag commented May 25, 2019

This is ready?

@jnewbery
Copy link
Contributor

jnewbery commented Jul 2, 2019

Is this still needed now that #15596 is merged?

@promag promag force-pushed the 2019-04-drop-getbalance-minconf branch from 595e5ad to 019872a Compare November 17, 2019 23:38
@promag
Copy link
Contributor Author

promag commented Nov 24, 2019

Also wallet label?

Ping @meshcollider.

@meshcollider
Copy link
Contributor

With the many minconf PRs and arguments we've had, I think we should at least briefly discuss this in the meeting to make sure people that haven't looked here are ok with the change

@ryanofsky
Copy link
Contributor

Conditional NACK until this has good release notes.

I don't like this change, but without a better alternative I think it might be an improvement over the status quo. The release notes here are bad though. If you're going to remove a feature ("tell me my balance ignoring incoming payments with less than min_conf confirmations") that once worked well enough and was more recently broken you should say why you are removing it and what possible alternatives are. I can try to write up some better release notes for this change today, and if anybody else has more information about past or present problems with this feature, it would be useful to post here. (Last discussions I remember having about this were about theoretical problems in potential future implementations of this feature.)

@promag
Copy link
Contributor Author

promag commented Nov 25, 2019

until this has good release notes.

Agree, these are poor, don't explain the motivation.

I don't like this change, but without a better alternative I think it might be an improvement over the status quo.

I was under the impression there was no intention in fixing the feature. If that's not the case then this should be closed.

Last discussions I remember having about this were about theoretical problems in potential future implementations of this feature

Yes, there's #14602 and also related discussion in #15596.

{
{"dummy", RPCArg::Type::STR, RPCArg::Optional::OMITTED_NAMED_ARG, "Remains for backward compatibility. Must be excluded or set to \"*\"."},
{"minconf", RPCArg::Type::NUM, /* default */ "0", "Only include transactions confirmed at least this many times."},
{"minconf", RPCArg::Type::NUM, /* default */ "0", "Must be zero"},
Copy link
Member

Choose a reason for hiding this comment

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

It's very confusing for this to be 0, because it won't actually show unconfirmed incoming transactions, only unconfirmed change. It's not even really 0 by default, but 1, see a few lines below. Since we can't drop it and can't rename it to dummy2, let's add a comment: This is ignored and only remains for backward compatibility. Must be excluded or set to zero.

@DrahtBot
Copy link
Contributor

🐙 This pull request conflicts with the target branch and needs rebase.

@DrahtBot
Copy link
Contributor

There hasn't been much activity lately and the patch still needs rebase. What is the status here?
  • Is it still relevant? ➡️ Please solve the conflicts to make it ready for review and to ensure the CI passes.
  • Is it no longer relevant? ➡️ Please close.
  • Did the author lose interest or time to work on this? ➡️ Please close it and mark it 'Up for grabs' with the label, so that it can be picked up in the future.

1 similar comment
@DrahtBot
Copy link
Contributor

There hasn't been much activity lately and the patch still needs rebase. What is the status here?
  • Is it still relevant? ➡️ Please solve the conflicts to make it ready for review and to ensure the CI passes.
  • Is it no longer relevant? ➡️ Please close.
  • Did the author lose interest or time to work on this? ➡️ Please close it and mark it 'Up for grabs' with the label, so that it can be picked up in the future.

@maflcko
Copy link
Member

maflcko commented Mar 21, 2022

Marked "up for grabs"

@fanquake fanquake closed this Apr 26, 2022
@promag promag deleted the 2019-04-drop-getbalance-minconf branch April 26, 2022 12:28
@promag promag restored the 2019-04-drop-getbalance-minconf branch April 26, 2022 12:28
@promag promag deleted the 2019-04-drop-getbalance-minconf branch April 26, 2022 12:28
@promag promag restored the 2019-04-drop-getbalance-minconf branch April 26, 2022 12:28
@promag promag deleted the 2019-04-drop-getbalance-minconf branch April 26, 2022 12:28
@bitcoin bitcoin locked and limited conversation to collaborators Apr 26, 2023
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.

rpc: remove getbalance::minconf

10 participants