phillc73/abettor

Expectation Failed

socratix opened this issue · 5 comments

Hi, I am sometimes getting an 'Expectation Failed' error when I try to submit bets using the placeOrder function. Is this a known issue? Is it to do with this?
https://forum.bdp.betfair.com/showthread.php?t=2901

Is there any known way to prevent this error when using abettor?

Many thanks.
Chris

Follow-up. This is specifically what I get:

selectionPlace
[1] "9438229" "10086349" "10277122" "10364717" "11079154" "11302725"
MarketId
[1] "1.128038083"
betsidePlace
[1] "BACK" "BACK" "BACK" "BACK" "BACK" "BACK"
betSizePlace
[1] 2 2 2 2 2 2
reqPricePlace
[1] 10.00 4.40 120.00 1.95 4.90 120.00
PlaceBetReturn <- placeOrders(marketId = MarketId,

  •                          selectionId = selectionPlace,  
    
  •                           betSide = betsidePlace,  
    
  •                           betType = "LIMIT",  
    
  •                           betSize = betSizePlace,  
    
  •                           reqPrice = reqPricePlace,  
    
  •                           persistenceType = "LAPSE"  
    
  •                           )  
    
    Error: Expectation Failed

Not seen or had this reported before. Will investigate and see what might be the problem.

Initially, I am wondering if pushing through six instructions in the one call could be the cause. Would you mind trying with just backing one selection first, then increasing until you hit the error?

I've done that, and found that I can indeed submit one by one, as long as I don't duplicate customer references in the call. Thanks!

To clarify: I have not increased the number of bets incrementally. I have just split into 6 separate calls. This is an acceptable workaround.

OK, thanks. I'm going to close this issue. If it becomes a show stopper for someone, I will re-open and address.

I appreciate you taking the time to report it and glad you're using abettor.