woocommerce-gateway-lightning icon indicating copy to clipboard operation
woocommerce-gateway-lightning copied to clipboard

Lightning payment complete, but Charge didn't register it?

Open rustyrussell opened this issue 6 years ago • 5 comments

@weex grabbed me on IRC; he paid but the UI was still spinning.

I checked the server, it has indeed been paid:

lightning-cli --lightning-dir ~/.lightning/mainnet/ listinvoice | grep c65791aab5ba8aed9b85b188bd6b7d5cb70238026f54d2d1a70c797ad8d9465e
	{ "label" : "gjxvasjiIwZb1H13wXgG7", "payment_hash" : "c65791aab5ba8aed9b85b188bd6b7d5cb70238026f54d2d1a70c797ad8d9465e", "msatoshi" : 212434387, "complete" : true, "pay_index" : 3, "msatoshi_received" : 212434387, "expiry_time" : 1516159063 }, 

In case it was just that the gui was stuck I told him to reload, but no joy:

https://twitter.com/weex/status/953488332649984000

He also hasn't received the conf. mail, so I think something is stuck?

rustyrussell avatar Jan 17 '18 04:01 rustyrussell

It looks like the order was properly registered on both Lightning Charge and WooCommerce ("Processing" means paid and waiting to be delivered), its just a UI glitch: he should be seeing the "thank you" page, but got sent to the payment page instead. Will look into that.

shesek avatar Jan 17 '18 09:01 shesek

I'm not sure it's just UI since I didn't get an email confirmation of the order. Maybe that's a separate issue but in any case, if I can get an order confirmation that'd be cool.

weex avatar Jan 17 '18 23:01 weex

OK, so we also discovered the SMTP gateway wasn't set up on the box, so that's a separate (configuration) bug.

BUT your order is complete. When we fix SMTP gateway I imagine they'll all go flooding out.

rustyrussell avatar Jan 18 '18 05:01 rustyrussell

@weex is it possible that you manually refreshed the page after making the payment, rather than the page automatically detecting the payment and updating itself?

It appears like WooCommerce throws that error when navigating directly to the payment page of a paid order. We should instead redirect the user to the thank you page in this case, but WooCommerce is throwing the error before the plugin has a chance to intervene. I'll look into ways to override their handling, or perhaps see if it makes sense to change that in WooCommerce itself.

shesek avatar Jan 18 '18 15:01 shesek

@shesek I got the payment screen, sent it, then after 5 or so minutes it hadn't reflected anything so I left the screen there, contacted Rusty and went away for an hour or so. When I came back it was the red bar with Processing message.

weex avatar Jan 18 '18 17:01 weex