1
0
Files
electrum/tests
SomberNight 37db6ea7e8 transaction: tx_from_any: rm all whitespaces from str, none from bytes
- whitespaces are safe to remove from strings, and is convenient if we do this for users
- bytes-like inputs should be left alone: individual bytes that look like whitespaces can appear in them anywhere
  - even stripping the leading/trailing whitespaces is not safe to do: the first byte of the nVersion or the last byte of the nLocktime might look like whitespace too!
- instead, leading/trailing whitespaces can be stripped closer to where they are input, e.g. in the GUI
  - e.g. ".txn" files that we ourselves create contain a complete tx as a hex string, with a trailing final newline in the file
    - instead of reading that as bytes, we can read it as text
  - ".psbt" files OTOH are binary
2025-12-11 16:48:50 +00:00
..
2025-08-27 15:31:43 +02:00
2024-06-10 20:22:20 +00:00