Running master 4d661ba:
```
src/bitcoin-cli combinepsbt [""] or src/bitcoin-cli combinepsbt []
```

```
  * frame #0: 0x000000010016054a bitcoind`PartiallySignedTransaction::PartiallySignedTransaction(PartiallySignedTransaction const&) [inlined] boost::optional_detail::optional_base<CMutableTransaction>::is_initialized(this=0x0000000000000000) const at optional.hpp:394 [opt]
    frame #1: 0x000000010016054a bitcoind`PartiallySignedTransaction::PartiallySignedTransaction(PartiallySignedTransaction const&) [inlined] boost::optional_detail::optional_base<CMutableTransaction>::optional_base(this=<unavailable>, rhs=0x0000000000000000) at optional.hpp:196 [opt]
    frame #2: 0x0000000100160542 bitcoind`PartiallySignedTransaction::PartiallySignedTransaction(PartiallySignedTransaction const&) [inlined] boost::optional<CMutableTransaction>::optional(this=0x000070000b9fe7c0, (null)=0x0000000000000000) at optional.hpp:958 [opt]
    frame #3: 0x0000000100160542 bitcoind`PartiallySignedTransaction::PartiallySignedTransaction(PartiallySignedTransaction const&) [inlined] boost::optional<CMutableTransaction>::optional(this=0x000070000b9fe7c0, (null)=0x0000000000000000) at optional.hpp:958 [opt]
    frame #4: 0x0000000100160542 bitcoind`PartiallySignedTransaction::PartiallySignedTransaction(this=0x000070000b9fe7c0, psbt_in=0x0000000000000000) at sign.h:576 [opt]
    frame #5: 0x0000000100142ae5 bitcoind`combinepsbt(JSONRPCRequest const&) [inlined] PartiallySignedTransaction::PartiallySignedTransaction(this=0x000070000b9fe700, psbt_in=<unavailable>) at sign.h:576 [opt]
    frame #6: 0x0000000100142ae0 bitcoind`combinepsbt(request=<unavailable>) at rawtransaction.cpp:1526 [opt]
    frame #7: 0x0000000100170f0a bitcoind`CRPCTable::execute(this=<unavailable>, request=0x000070000b9fead0) const at server.cpp:557 [opt]
```
{
    if (request.fHelp || request.params.size() < 1 || request.params.size() > 2)
        throw std::runtime_error(
            RPCHelpMan{"finalizepsbt",
                "Finalize the inputs of a PSBT. If the transaction is fully signed, it will produce a\n"
                "network serialized transaction which can be broadcast with sendrawtransaction. Otherwise a PSBT will be\n"
                "created which has the final_scriptSig and final_scriptWitness fields filled for inputs that are complete.\n"
                "Implements the Finalizer and Extractor roles.\n",
                {
                    {"psbt", RPCArg::Type::STR,  false,  "", "A base64 string of a PSBT"},
                    {"extract", RPCArg::Type::BOOL,  true,  "true", "If true and the transaction is complete,\n"
            "                             extract and return the complete transaction in normal network serialization instead of the PSBT."},
                },
                RPCResult{
            "{\n"
            "  \"psbt\" : \"value\",          (string) The base64-encoded partially signed transaction if not extracted\n"
            "  \"hex\" : \"value\",           (string) The hex-encoded network transaction if extracted\n"
            "  \"complete\" : true|false,   (boolean) If the transaction has a complete set of signatures\n"
            "  ]\n"
            "}\n"
                },
                RPCExamples{
                    HelpExampleCli("finalizepsbt", "\"psbt\"")
                },
            }.ToString());
    RPCTypeCheck(request.params, {UniValue::VSTR, UniValue::VBOOL}, true);
    
    PartiallySignedTransaction psbtx;
    std::string error;