Author

Topic: These testnet outputs are not making sense to me. What's going on? (Read 185 times)

newbie
Activity: 4
Merit: 2
You're right. I didn't immediately see fee values in the tx explorer so I just assumed testnet transactions didn't have those. Thanks!
legendary
Activity: 3472
Merit: 10611
i am going to write numbers in satoshi to make it easier:
you sent 10000 satoshi and 50000 satoshi to mxdnjqD875oeVGzc88z3vmpL6MmimdWAZr so your balance is 60000 satoshi.

then you sent tx #2 92287c75.... (which is the first transaction you sent) that is sending 1000 satoshi to mkRHp1qT3rXp4LukVAkD8ghWM1a1NX6m4r the "cost" of this transaction is the fee you must pay the miners and  the fee you paid is 20792 satoshi. so out of your 60k you are left with 38,208 satoshi. (60000-1000-20792)

then you create another tx#1 91224995f2... (the second transaction) and send 1000 satoshi to mkRHp1qT3rXp4LukVAkD8ghWM1a1NX6m4r this transaction fee is 34408 satoshi so you are left with (38208-1000-34408) 2,800 satoshi
hence the balance of 0.00002800 tBTC
newbie
Activity: 4
Merit: 2
Today I took some time to mess around with the bit Python library (https://github.com/ofek/bit), which I find pretty easy to use. I have been wanting to do some Bitcoin programming for a while, soo I decided to create a simple web wallet to test creating and broadcasting transactions. I'm obviously using testnet for this.

I initially used a testnet faucet to send two transactions to a main address, 0.0005 and 0.0001 tBTC to get started. I used my code to check for this address' balance and got 0.0006, cool. I then proceeded to used my newly developed web wallet to send two transactions to another address, both with a value of 0.00001 tBTC. I immediately noticed the balance from my main address was off, showing me 0.000028 tBTC which to me makes no sense, it should have been something close to 0.00058. I used blockcypher to check on those transactions (which are unconfirmed, but I believe this is irrelevant) to make sure my code was ok. Sure enough, 0.00001 tBTC was sent twice to the correct address, but the change sent back to the sender address is way off. What exactly happened here?

The transactions:
#1: https://live.blockcypher.com/btc-testnet/tx/91224995f2c240159141a499b91db8d26f0a6425fb12f5277d2f735576596aa7/
#2: https://live.blockcypher.com/btc-testnet/tx/92287c75721563643f8dbf9ee5fff59abe1c9b6b36a638daa05c35d5fea981d0/

Thanks in advance!
Jump to: