While reviewing #31622 I noticed that the constant name (SCRIPT_)ERR_SIG_HASHTYPE
is used for two different script verification error codes, namely one for legacy and one for Schnorr signatures:
https://github.com/bitcoin/bitcoin/blob/eba5f9c4b63fe46261fbb3e71b9a94832d105b23/src/script/script_error.cpp#L56-L57 https://github.com/bitcoin/bitcoin/blob/eba5f9c4b63fe46261fbb3e71b9a94832d105b23/test/functional/feature_taproot.py#L600
In order to resolve this confusion, this PR adapts all script error constant names in the functional tests (currently only in feature_taproot.py) to the ones used in our C++ codebase (see script_error.cpp) with a scripted diff. This also makes checking whether we have test coverage for a certain script error easier.