ripple / ripple-client

A UI for the Ripple payment network built using web technologies
ISC License
1.34k stars 493 forks source link

Transaction fails when sending ripple to self (backed by USD in account) #933

Closed shuvrobiswas closed 9 years ago

shuvrobiswas commented 11 years ago

When I try to send ripples to my self, I get the usual:

"What's the point of sending XRP to yourself?

Calculating alternatives:

X USD"

When I click 'Send USD' -> 'Confirm' I get the following error:

"Transaction failed!

Error: Path could not send full amount."

I tried this several times (and clicked as quick as possible to make sure whatever path it calculated doesn't get "lost"); I get the same message every time. I tried mostly for 1000 xrp, a few times for 2000 xrp, and once for 100 xrp. I get the same message everytime.

JoelKatz commented 11 years ago

This is probably a server bug due to XRP rounding. The amount of USD that needs to go into the path is probably not rounded up enough, causing the XRP that comes out to be rounded at least one drop less than the destination amount in the transaction. By rule, if less XRP comes out than requested, the transaction fails.

I'd appreciate it if you can replicate this for me and let know your account and the current ledger at the time you did it. You can get the current ledger from ripplecharts.com, on the right, it's a seven-digit number next to the words "Ledger Index". You can email your Ripple address to me if you don't want to make it public, david@ripple.com. (Of, if you can get the transaction ID, that's even better.) This will allow me to use your transaction as a test case to make sure any change we make actually fixes the problem.

shuvrobiswas commented 11 years ago

Sent you an email with the info :)

JoelKatz commented 11 years ago

Thank you.

dchapes commented 11 years ago

Related to this I tried a few small XRP self payments using USD/Bitstamp and got the same thing. E.g. tx 0BD1DAD7CD9D392E1084E15F2E09725A959AA90B65225DC48D1E5765E16552A9. However, if I changed the transaction from the standard of having SendMax in USD/my_addr and USD/Bitstamp as the first step in the path to instead using USD/Bitstamp in SendMax and only the XRP offer in the path then it worked fine, e.g. tx E4A7B9C323E9F0D223838D5D4296A41CEE8B9D3D74A532FAD1D28DE2A4D9AA44.