OpenBazaar / openbazaar-go

OpenBazaar 2.0 Server Daemon in Go
MIT License
994 stars 283 forks source link

BCH Purchase Stalls #1000

Open christroutner opened 6 years ago

christroutner commented 6 years ago

I brought this up in the #support channel on Slack and @placer14 asked me to file it as an issue.

Client version: 2.2.1 Server version: 0.12.0

Context: I'm doing test sales for P2P VPS. I have two cloud Ubuntu 16.04 servers, fully connected to the internet (no firewalls), making a BCH transaction over OB.

The Buyer pays for the purchase through the built-in BCH wallet on the desktop app, but the screen stalls out with spinny, animated waiting gif. I'll include a screenshot of this screen. It stays stuck on this screen. If I refresh the app, and go to the Purchases screen, the order shows a status of 'Awaiting Payment'. Subsequent attempts to pay the order stall out as above.

On the seller side, the payment and order notification come through just fine. The automated software for P2P VPS picks up on the notification and fulfills the order. So from the Seller viewpoint, everything is working correctly.

Back on the Buyer side, the fulfillment notification is never received and the order remains in an 'Awaiting Payment' state.

@placer14 had me check the terminal output of the Buyer and I noticed this line:

...
OpenBazaarDecoder.decode: Type assertion failed, missing 'BCH' field
2018/07/04 01:42:43 http: multiple response.WriteHeader calls
...

I also checked the logs, and everything looked normal.

christroutner commented 6 years ago

image

christroutner commented 6 years ago

Above is the screenshot with spinny, waiting gif. This is where the Buyer side of the transaction stalls.

cpacia commented 6 years ago

Is this is the master branch or a release?

christroutner commented 6 years ago

This is release. Both servers are using the 0.12.0 Docker container here: https://hub.docker.com/r/openbazaar/server/tags/

christroutner commented 6 years ago

Actually, I take that back. The seller is using the Docker container. The buyer is using the master branch of openbazaar-go.

cpacia commented 6 years ago

You know I might have experienced something like this today. I think it fetches the exchange/fee rates at that point. When I did it, it eventually showed up after like a minute. Might just have been a really slow return for the API call.

Did it eventually come back for you?

christroutner commented 6 years ago

No, it never comes back. Hangs forever. I've waited 10 - 20 minutes. It stalls out consistently.

christroutner commented 6 years ago

I just double checked and the seller was using the 0.12.0-rc3 release. Just updated to 0.12.0, but I'm getting the same results. Can still consistently reproduce the behavior.

christroutner commented 6 years ago

I was thinking this issue might be due to corruption of the database or wallet. I blew away the .openbazaar2.0 directory on both servers, reinitialized, and recreated the OB store on both. I can still reproduce the behavior.