Bitcoin Forum
May 11, 2024, 04:14:44 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: What is wrong with this raw transaction?  (Read 687 times)
CIYAM (OP)
Legendary
*
Offline Offline

Activity: 1890
Merit: 1078


Ian Knowles - CIYAM Lead Developer


View Profile WWW
November 07, 2013, 12:10:46 PM
 #1

I have the following raw transaction (which was created via "createrawtransaction" and successfully signed with "signrawtransaction"):

Code:
0100000001c6689b75fcd871d1ed428e4630163601183288628d5fbe5c76c7339003b0e828000000008b48304502203deb0b9f61c88bc2bb5df24acb330b6cf1f2b9b8140203cafbf5db29935dd2a60221009c7c5fc049daf358ec392c0387022218b971a2f0c50386947e3b30c71f4bd2d201410408dc1b7167df71b68c12ec0a7e77ccb602cbcb1966f3bff773c925530905d3996e7a6c7eb8a404d5dbebff428ed36d1b9c8ab70dfebe9e80e0bd6b1dd298b677ffffffff01807c4301000000001976a91407dd428c4c6f8752d5ded10edabab12d912de14e88ac00000000

which if I paste after decoderawtransaction gives me the following:

Code:
{
"txid" : "c4b58d28e59e08c6cfa6272a8b56471896833aa20a5f2b05a952e6f9f0421e46",
"version" : 1,
"locktime" : 0,
"vin" : [
{
"txid" : "28e8b0039033c7765cbe5f8d6288321801361630468e42edd171d8fc759b68c6",
"vout" : 0,
"scriptSig" : {
"asm" : "304502203deb0b9f61c88bc2bb5df24acb330b6cf1f2b9b8140203cafbf5db29935dd2a60221009c7c5fc049daf358ec392c0387022218b971a2f0c50386947e3b30c71f4bd2d201 0408dc1b7167df71b68c12ec0a7e77ccb602cbcb1966f3bff773c925530905d3996e7a6c7eb8a404d5dbebff428ed36d1b9c8ab70dfebe9e80e0bd6b1dd298b677",
"hex" : "48304502203deb0b9f61c88bc2bb5df24acb330b6cf1f2b9b8140203cafbf5db29935dd2a60221009c7c5fc049daf358ec392c0387022218b971a2f0c50386947e3b30c71f4bd2d201410408dc1b7167df71b68c12ec0a7e77ccb602cbcb1966f3bff773c925530905d3996e7a6c7eb8a404d5dbebff428ed36d1b9c8ab70dfebe9e80e0bd6b1dd298b677"
},
"sequence" : 4294967295
}
],
"vout" : [
{
"value" : 0.21200000,
"n" : 0,
"scriptPubKey" : {
"asm" : "OP_DUP OP_HASH160 07dd428c4c6f8752d5ded10edabab12d912de14e OP_EQUALVERIFY OP_CHECKSIG",
"hex" : "76a91407dd428c4c6f8752d5ded10edabab12d912de14e88ac",
"reqSigs" : 1,
"type" : "pubkeyhash",
"addresses" : [
"1iankj4HSpksoUgXSm8G7Gf7dkvLP3V9d"
]
}
}
]
}

but if I attempt to send it using sendrawtransaction then I get the TX rejected (code -22) error (which I think is normally for badly formatted JSON data).

With CIYAM anyone can create 100% generated C++ web applications in literally minutes.

GPG Public Key | 1ciyam3htJit1feGa26p2wQ4aw6KFTejU
1715444084
Hero Member
*
Offline Offline

Posts: 1715444084

View Profile Personal Message (Offline)

Ignore
1715444084
Reply with quote  #2

1715444084
Report to moderator
BitcoinCleanup.com: Learn why Bitcoin isn't bad for the environment
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
dserrano5
Legendary
*
Offline Offline

Activity: 1974
Merit: 1029



View Profile
November 07, 2013, 01:18:35 PM
 #2

Seems like the txid referenced in the vin doesn't exist. Both my localbitcoind and blockchain.info don't know about it.

Code:
$ bitcoind getrawtransaction 28e8b0039033c7765cbe5f8d6288321801361630468e42edd171d8fc759b68c6
error: {"code":-5,"message":"No information available about transaction"}

I'm running with txindex=1.
CIYAM (OP)
Legendary
*
Offline Offline

Activity: 1890
Merit: 1078


Ian Knowles - CIYAM Lead Developer


View Profile WWW
November 07, 2013, 01:33:36 PM
 #3

Seems like the txid referenced in the vin doesn't exist. Both my localbitcoind and blockchain.info don't know about it.

Ah - thanks for that (I know what I've done wrong now).

It's a pity the error handling for the raw transactions API is so minimal.

With CIYAM anyone can create 100% generated C++ web applications in literally minutes.

GPG Public Key | 1ciyam3htJit1feGa26p2wQ4aw6KFTejU
DannyHamilton
Legendary
*
Offline Offline

Activity: 3388
Merit: 4653



View Profile
November 07, 2013, 06:03:11 PM
 #4

It's a pity the error handling for the raw transactions API is so minimal.

+1
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!