CounterpartyXCP / counterwallet

Counterparty web wallet
https://counterwallet.io
147 stars 177 forks source link

Betting resolution date incorrect #883

Open jdogresorg opened 5 years ago

jdogresorg commented 5 years ago

I think I found an issue with counterwallet betting and the bet resolution date parsing.

I created a broadcast/feed which expired in 1 hour, and then tried to bet on that feed in counterwallet. The betting information came up, so counterwallet is correctly detecting that the feed can still accept bets. However, the resolution date that is displayed is actually in the past, and trying to place bets on the feed results in errors about the deadline already being passed.

  1. Tx shows broadcast date/deadline of 1539889200 (2018-10-18T19:00:00Z)... in the future https://testnet.xchain.io/tx/21866 image

  2. Counterwallet shows deadline of 2018/10/17 09:00:00 PM -07:00... which is in the past. image

  3. Trying to bet on the feed passes a deadline of 1539835200 to create_bet.. resulting in an API error image

jdogresorg commented 5 years ago

It seems that the "Deadline" field is being completely ignored in bets and the same value is always being sent for 'deadline'.

Screenshot of 10/29 date entered when trying to place bet image API request to Counterparty passes wrong date/unixtime image

Screenshot of 10/30 date entered when trying to place bet image API request to Counterparty passes wrong date/unixtime... same deadline as previous request image