-
Notifications
You must be signed in to change notification settings - Fork 37.7k
validation: Rename CheckInputs to CheckInputScripts #16658
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
Conversation
This comment has been minimized.
This comment has been minimized.
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. ConflictsReviewers, 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. |
4618cf2
to
bf5b449
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Concept ACK
This builds on #13868. Please review that PR first.
I have reviewed the base PR.
Should 046cd75 be a scripted-diff? This should produce the same change:
gsed -i 's/\<CheckInputs\>/CheckInputScripts/g' src/*.h src/*.cpp src/**/*.h src/**/*.cpp
This needs a couple functional test changes for the expected messages:
bitcoin/test/functional/feature_dersig.py
Line 127 in 7d6f63c
with self.nodes[0].assert_debug_log(expected_msgs=['CheckInputs on {} failed with non-mandatory-script-verify-flag (Non-canonical DER signature)'.format(block.vtx[-1].hash)]): |
bitcoin/test/functional/feature_cltv.py
Line 141 in 7d6f63c
with self.nodes[0].assert_debug_log(expected_msgs=['CheckInputs on {} failed with non-mandatory-script-verify-flag (Negative locktime)'.format(block.vtx[-1].hash)]): |
bf5b449
to
41d1528
Compare
Rebased and removed WIP tag. Thanks for the review @fanquake
Fixed. Thanks.
I think this is small enough to be a non-scripted commit, and I'd need to add more to your suggested one-liner to make the test changes atomic with the validation.cpp changes. I'm leaving as it is for now, but can change if other reviewers agree that scripted would be better. |
FWIW, I believe a valid scripted-diff line for 3623a8f would be:
|
41d1528
to
d0dd908
Compare
I've updated the commit to use your scripted diff one-liner. Thanks! |
Concept ACK. I ran a |
@jnewbery Looks like the scripted diff needs fixing: $ set -o errexit; source ./ci/lint/06_script.sh
Error: script block marker but no scripted-diff in title
Failed |
Thanks. Will fix next week. |
d0dd908
to
3386c65
Compare
should be fixed |
3386c65
to
3ee9ad7
Compare
rebased |
ACK 3ee9ad7 thanks for fixing documentation Show signature and timestampSignature:
Timestamp of file with hash |
rebased |
3ee9ad7
to
44d20b8
Compare
re-ACK 44d20b8 only change is rebase the scripted diff Show signature and timestampSignature:
Timestamp of file with hash |
TIL Code review ACK. |
44d20b8
to
ff6fa17
Compare
Rebased on master |
Needs rebase |
This is a trivial fix that should be ready for merge after rebase |
CheckInputs() used to check no double spends, scripts & sigs and amounts. Since 832e074, the double spend and amount checks have been moved to CheckTxInputs(), and CheckInputs() now just validates input scripts. Rename the function to CheckInputScripts(). -BEGIN VERIFY SCRIPT- sed -i -E -e 's/CheckInputs\b/CheckInputScripts/g' $(git grep -l CheckInputs | grep -v doc/) -END VERIFY SCRIPT-
ff6fa17
to
3bd8db8
Compare
Rebased |
re-ACK 3bd8db8, did the rebase myself, checked the scripted diff 👡 Show signature and timestampSignature:
Timestamp of file with hash |
ACK 3bd8db8 |
3bd8db8 [validation] fix comments in CheckInputScripts() (John Newbery) 6f6465c scripted-diff: [validation] Rename CheckInputs to CheckInputScripts (John Newbery) Pull request description: CheckInputs() used to check no double spends, scripts & sigs and amounts. Since 832e074, the double spend and amount checks have been moved to CheckTxInputs(), and CheckInputs() now just validates input scripts. Rename the function to CheckInputScripts(). Also fix incorrect comments. ACKs for top commit: MarcoFalke: re-ACK 3bd8db8, did the rebase myself, checked the scripted diff 👡 promag: ACK 3bd8db8Tree-SHA512: 7b3f8597d210492798fb784ee8ea47ea6377519111190161c7cc34a967509013f4337304f52e9bedc97b7710de7b0ff8880e08cd7f867754567f82e7b02c794c
3bd8db8 [validation] fix comments in CheckInputScripts() (John Newbery) 6f6465c scripted-diff: [validation] Rename CheckInputs to CheckInputScripts (John Newbery) Pull request description: CheckInputs() used to check no double spends, scripts & sigs and amounts. Since 832e074, the double spend and amount checks have been moved to CheckTxInputs(), and CheckInputs() now just validates input scripts. Rename the function to CheckInputScripts(). Also fix incorrect comments. ACKs for top commit: MarcoFalke: re-ACK 3bd8db8, did the rebase myself, checked the scripted diff 👡 promag: ACK 3bd8db8Tree-SHA512: 7b3f8597d210492798fb784ee8ea47ea6377519111190161c7cc34a967509013f4337304f52e9bedc97b7710de7b0ff8880e08cd7f867754567f82e7b02c794c
3bd8db8 [validation] fix comments in CheckInputScripts() (John Newbery) 6f6465c scripted-diff: [validation] Rename CheckInputs to CheckInputScripts (John Newbery) Pull request description: CheckInputs() used to check no double spends, scripts & sigs and amounts. Since 832e074, the double spend and amount checks have been moved to CheckTxInputs(), and CheckInputs() now just validates input scripts. Rename the function to CheckInputScripts(). Also fix incorrect comments. ACKs for top commit: MarcoFalke: re-ACK 3bd8db8, did the rebase myself, checked the scripted diff 👡 promag: ACK 3bd8db8Tree-SHA512: 7b3f8597d210492798fb784ee8ea47ea6377519111190161c7cc34a967509013f4337304f52e9bedc97b7710de7b0ff8880e08cd7f867754567f82e7b02c794c
Summary: 3bd8db80d8d335ab63ece4f110b0fadd562e80b7 [validation] fix comments in CheckInputScripts() (John Newbery) 6f6465cefcd599c89c00f7b51f42a4b87a5ffb0b scripted-diff: [validation] Rename CheckInputs to CheckInputScripts (John Newbery) Pull request description: CheckInputs() used to check no double spends, scripts & sigs and amounts. Since 832e074, the double spend and amount checks have been moved to CheckTxInputs(), and CheckInputs() now just validates input scripts. Rename the function to CheckInputScripts(). Also fix incorrect comments. --- Backport of Core [[bitcoin/bitcoin#16658 | PR16658]] Test Plan: ninja all check check-functional Reviewers: #bitcoin_abc, deadalnix Reviewed By: #bitcoin_abc, deadalnix Subscribers: deadalnix Differential Revision: https://reviews.bitcoinabc.org/D8762
CheckInputs() used to check no double spends, scripts & sigs and amounts. Since
832e074, the double spend and amount checks
have been moved to CheckTxInputs(), and CheckInputs() now just validates
input scripts. Rename the function to CheckInputScripts().
Also fix incorrect comments.