We have methods to convert a script to a `WScritpHash` and `ScriptHash`, no need to do this manually, let alone use the `psbt::Serialize` trait to do so.