Multibit-Legacy / multibit-hd

Deprecated Bitcoin Wallet
https://multibit.org/blog/2017/07/26/multibit-shutdown.html
Other
171 stars 113 forks source link

Complete tx when not enough money should be handled by app #712

Closed jim618 closed 8 years ago

jim618 commented 8 years ago

Appears to be getting thru to the CrashReporter:

error report uploaded. Id: 0729933

MultiBit HD version: 0.1.2
Operating system: 64 6.1 Windows 7

User notes length: 131

Number of stack traces: 1
First stack trace:
org.bitcoinj.core.InsufficientMoneyException: Insufficient money,  missing 43146214 satoshis
    at org.bitcoinj.core.Wallet.calculateFee(Wallet.java:4707) ~[multibit-hd.jar:na]
    at org.bitcoinj.core.Wallet.completeTx(Wallet.java:3708) ~[multibit-hd.jar:na]
    at org.multibit.hd.core.services.BitcoinNetworkService.completeWithoutSigning(BitcoinNetworkService.java:902) [multibit-hd.jar:na]
    at org.multibit.hd.core.services.BitcoinNetworkService.prepareTransaction(BitcoinNetworkService.java:749) [multibit-hd.jar:na]
    at org.multibit.hd.ui.views.wizards.send_bitcoin.SendBitcoinWizardModel.prepareTransaction(SendBitcoinWizardModel.java:454) [multibit-hd.jar:na]
    at org.multibit.hd.ui.views.wizards.send_bitcoin.SendBitcoinWizardModel.showNext(SendBitcoinWizardModel.java:166) [multibit-hd.jar:na]
    at org.multibit.hd.ui.views.wizards.AbstractWizard$6$1.run(AbstractWizard.java:391) [multibit-hd.jar:na]
    at java.awt.event.InvocationEvent.dispatch(Unknown Source) [na:1.7.0_80]
    at java.awt.EventQueue.dispatchEventImpl(Unknown Source) [na:1.7.0_80]
    at java.awt.EventQueue.access$300(Unknown Source) [na:1.7.0_80]
gary-rowe commented 8 years ago

Might justify a quick addition to the code for 0.1.3. Should be trivial to add the appropriate catch blocks.

jim618 commented 8 years ago

It is already covered with an Exception catch. I've changed the logging so that it just logs the class and message to keep the stacktrace out of the log.

I'll leave this open for further investigation for 0.1.4

jim618 commented 8 years ago

I've checked that sending too large an amount (more than you've got in the wallet) is handled correctly by the UI.

jim618 commented 8 years ago

Nothing more to do on this one.

@gary-rowe Please review and close.

gary-rowe commented 8 years ago

Looks good to me. Closing.