How to reproduce: Build a transaction with ~190 inputs, get the hex and issue testmempoolaccept [\"{txhex}\"] in the GUI console. It'll give back a TX decode failed (code -22) with a stripped txhex where the end is cut down.
GUI: testmempoolaccept in console cuts the end of the txhex #17618
issue nopara73 opened this issue on November 27, 2019-
nopara73 commented at 6:54 AM on November 27, 2019: none
- nopara73 added the label good first issue on Nov 27, 2019
-
0xB10C commented at 9:39 AM on November 27, 2019: member
How long (in chars) is the is your txhex? How many chars are cut off? How long is the returned txhex?
- laanwj added the label GUI on Nov 27, 2019
- laanwj removed the label good first issue on Nov 27, 2019
- laanwj added the label RPC/REST/ZMQ on Nov 27, 2019
-
laanwj commented at 10:34 AM on November 27, 2019: member
I think this is a known issue. Qt cannot handle very large data input, it cuts off at some point. Fixing this would mean implementing a "scalable" input field that still performs well with large amount of pasted data, which is a non-trivial feat of UI engineering, so I've removed the "Good first issue" label.
Does this also happen if you use RPC through the cli? (if your shell runs into problems too, try input from stdin with
-stdin, it's one reason that option was added) -
nopara73 commented at 1:06 PM on November 27, 2019: none
Does this also happen if you use RPC through the cli? (if your shell runs into problems too, try input from stdin with -stdin, it's one reason that option was added)
Yes, I'm on Windows though. I tried it both with command line and powershell and both of them are cutting it. @0xB10C After reading @laanwj's reply I think answers for your questions are irrelevant. If you think it's still helpful, I can dig it up and give you exact numbers.
Overall, it's a bit annoying, but oh well, if nobody feels like fixing it, it's not the end of the world, in that case just let the robot to autoclose the issue after it gets too old.
-
instagibbs commented at 3:28 PM on November 27, 2019: member
if you can share the exact setup/hex somewhere I can take a stab diagnosing at least. I'm not sure the Core wallet is even allowed to make something so large :)
-
laanwj commented at 12:13 PM on November 28, 2019: member
Yes, I'm on Windows though. I tried it both with command line and powershell and both of them are cutting it.
At the same length?
@0xB10C After reading @laanwj's reply I think answers for your questions are irrelevant.
If it also happens with
-cli, even in-stdinmode (so when piping in arguments instead of on the command line). I don't think so. It may be something else than the GUI issue that I expected. -
0xB10C commented at 3:39 PM on November 28, 2019: member
Did some experimenting on Linux with
bitcoin-cli, not the GUI console. Can't comment on Windows.
- 95ba007be428dba2a4ec725a878437ce7033fb41e56a994a4174444106bffede
- 202 inputs
- 59737 chars
bitcoin-cli testmempoolaccept [\"$(bitcoin-cli getrawtransaction 95ba007be428dba2a4ec725a878437ce7033fb41e56a994a4174444106bffede)\"]works fine.
- 1324108af3d8193095b0b5e19bf3d4d678e976a12be28f0c7fcca303a1c9a586
- 378 inputs
- 111605 chars
bitcoin-cli testmempoolaccept [\"$(bitcoin-cli getrawtransaction 1324108af3d8193095b0b5e19bf3d4d678e976a12be28f0c7fcca303a1c9a586)\"]works fine.
- 6723a56bdf434633315ae78acfd08ef8a2fb5ff15a84bf4c729f09d9e8eb9aac
- 533 inputs
- 157277 chars
bitcoin-cli testmempoolaccept [\"$(bitcoin-cli getrawtransaction 6723a56bdf434633315ae78acfd08ef8a2fb5ff15a84bf4c729f09d9e8eb9aac)\"] -bash: /usr/bin/bitcoin-cli: Argument list too longDoes not work, but that's a Linux kernel restriction. Works with
-stdinas expected.echo [\"$(bitcoin-cli getrawtransaction 6723a56bdf434633315ae78acfd08ef8a2fb5ff15a84bf4c729f09d9e8eb9aac)\"] | bitcoin-cli --stdin testmempoolaccept
edit: over read that the issue is on the GUI console and not on the RPC interface.
-
nopara73 commented at 2:55 AM on November 30, 2019: none
At the same length?
No. That's why I did not report it in my original post, because the cut happens before the command is sent, so that has nothing to do with Core.
-
laanwj commented at 9:18 AM on December 3, 2019: member
According to the documentation of QLineEdit on the
maxLengthproperty (https://doc.qt.io/qt-5/qlineedit.html#maxLength-prop)By default, this property contains a value of 32767.It doesn't say that the value can't be increased to a larger number. Though, it would have to be tested that the GUI doesn't become unusably slow, which I expect to be the reason for the limit.
- MarcoFalke renamed this:
`testmempoolaccept` cuts the end of the txhex
GUI: testmempoolaccept in console cuts the end of the txhex
on Dec 3, 2019 - fanquake closed this on Jul 9, 2020
- sidhujag referenced this in commit 01c1227dea on Jul 9, 2020
- PastaPastaPasta referenced this in commit efc7836a07 on Jun 27, 2021
- PastaPastaPasta referenced this in commit f0ec1cd1fe on Jun 28, 2021
- PastaPastaPasta referenced this in commit 44ae4b6fd9 on Jun 29, 2021
- PastaPastaPasta referenced this in commit 3193ddc6ce on Jul 1, 2021
- PastaPastaPasta referenced this in commit 9251480fa8 on Jul 1, 2021
- PastaPastaPasta referenced this in commit 9a486ef89a on Jul 15, 2021
- PastaPastaPasta referenced this in commit 959a031bf8 on Jul 16, 2021
- Fabcien referenced this in commit 4e58da2388 on Aug 31, 2021
- MarcoFalke locked this on Feb 15, 2022
- gades referenced this in commit e08d68e4cc on May 9, 2022