VBNet Sample (Yes really)

Collapse
This is a sticky topic.
X
X
 
  • Time
  • Show
Clear All
new posts

  • SimonN
    replied
    Thank you as always, Jabe!

    haha your system sounds epic - you should do us all a lil video of it in action lol- or maybe that would be giving the game away or something like that on your top secret plans!!

    BF support assured me that whenever a market is closed it remains closed and never will be reopened and that closed is safe to delete our records.

    Cheers, Si

    Leave a comment:


  • jabe
    replied
    I'm aware that there may be odd things happen now and then, and I'm not at all certain how my program will deal with them. It is meant to be mostly automatic, but there are situations I still have to deal with.

    My program has a form with upwards of a dozen assorted tabs relaying information, though betting will be automated (one day, one day...). One of these tabs is there to tell me how any betting is going and whether anything odd has happened. I don't remember whether your program is a bot without a GUI, but if it has a GUI, how would it be if it reported back such oddities and left you with the option to make a decision, based on a bit of research, that the prog would be able to handle?

    Not long after I started testing my program, there was a minor game somewhere that eventually started several days after Betfair's claimed date and time. There'll always be games that have a delay in them (there was a floodlight failure in a game at Sunderland a couple of weeks ago). Some games might never restart.

    It's not uncommon for a kickoff in England to be delayed 15 minutes at the discretion of the referee. I guess it depends when bets would be placed on your game. If something's clearly amiss and no bets have been placed, I'd be inclined not to bet on the game. There's always plenty more.

    No idea if this was any help!

    Leave a comment:


  • SimonN
    replied
    Helllllllo again guys,

    One for you gurus here I think..

    So we were sending out 40 marketId's of football matches off to BF for best offers when we suddenly realised that even though we were making 40 marketIds request that didnt necessarily mean we were getting 40 marketid responses WITH MARKET STATUS OPEN back!!

    Because we know that these games - well going by the event date at least anyway - hadnt already kickoff then we wondered what the circumstances could be that would return marketstatus as something other than open or even closed itself and how we should deal with these records in our database.

    When this happens should we delete these marketId's in the database or simple overlook the fact that betfair didnt update odds with an non open status?? In which case they would read on our system in effect as static prices stuck at last time served by the last odds update like a broken watch. (they would eventually get deleted anyway when the event date was triggered).

    OR should we delete them concluding that betfair has finished with them?

    Is there even any situations where betfair reopen the status of the marketbook response and change it from closed to reopened?

    I'm trying to think of under what circumstances such could happen.

    Maybe an event is under threat from weather or some kind of incident - that would make the decision as to whther or not the game would take place uncertain? maybe in tht case betfair could make it marketbook response as no longer open (closed) but then maybe they decide to play the game anyway so does bf then revert the response back to open again?

    Or maybe betfair event date was wrong and the game was in fact already finished but not according to the event date as this was incorrectly stated?

    I think Ive seen one or two examples when betfair had potentially at least made a mistake in how they listed a market. Just the other day they had the home and away teams swapped round to be different than seemingly everyone else out there.


    Cheers guys much appreciated as always

    Simon
    Last edited by SimonN; 01-12-2016, 10:53 AM.

    Leave a comment:


  • jabe
    replied
    I didn't get chance to do the comparison of returned MarketTypes. Not sure why, but my laptop did a surprise reboot the other day and taken away my data with it.

    I had fun when I added the listCountryCodes to my program in whichever century that was. In order to get some kind of sensible sequence of football matches displayed, I use date-kickofftime-countrycode-hometeamname as a sort key for the display. Unfortunately the listCountryCodes call doesn't have anything for international games, so I had to catch such games with something else.

    After coming across a few missing countries, I ended up creating my own countryCode text file using data from a website that listed all the codes (along with a few extra). So the prog reads my file, stores all the records on key, then gets the ones from Betfair and adds any that might not be on my file.

    Leave a comment:


  • SimonN
    replied
    Thanks BetDynamics,

    From what I recall, my reason for wanting MarketType was because I made a request for MATCH_ODDS and nothing was returned so I wondered, being a lower level game, whether it was listed as UNMANAGED_MATCH_ODDS.

    When neither approaches yielded the market or event (I forget now) I wanted to check whether I had the correct code for unmanaged matches and this was where I was surprised that nothing was returned.

    Obviously Betfair wasnt carrying that game but I just thought it strange that look up code was only returned when currently in use.

    Then again I am as you know pretty new to all this so it's quite likely that my database lookup table approach is out of date with this kind of thing.

    Leave a comment:


  • betdynamics
    replied
    Originally posted by SimonN View Post
    Seems bizzare way of doing it that reference table look up values would disappear just because no example currently exists.
    It's always worked that way.

    For example:

    listCompetitions gives you a list of current competitions with active markets, not all competitions ever followed by Betfair.

    listCountries gives you a list of current countries with active markets, not all countries where events could occur or have occurred in the past.

    In essence, you are not looking at the complete reference table, you are looking at an extract of the data (for active markets) and operating against that extract.

    Out of interest, why call listMarketTypes when you already know the market type?

    Leave a comment:


  • jabe
    replied
    I've done a couple of calls - one this afternoon and one in the early morning, and I'll see if there are any differences. All those returned have a figure for the number of current markets of that type, and it's never zero. I'll post any differences I find.

    Leave a comment:


  • SimonN
    replied
    Thank you always, Jabe.

    I'm not going mad after all then (well least not in this regard anyway).

    Seems bizzare way of doing it that reference table look up values would disappear just because no example currently exists.

    Leave a comment:


  • jabe
    replied
    Originally posted by SimonN View Post
    MATCH_ODDS_UNMANAGED still used? Depricated?

    Made AJAX call using to Visualiser to ListMarketTypes with 'Market Types' set to 'MATCH_ODDS_UNMANAGED' only and nothing returned?

    Surely, it can't just be there as a reference code only when there happens to be some events currently using it?

    Thank you
    I did a similar call a while back - I think I posted the results somewhere (can't find it, so maybe I didn't) - and my conclusion, given a few glaring omissions in the returned data, was that, yes, the listMarketTypes call only brings back marketTypes for which there is currently a market somewhere. So an absence just means there is currently not a market of that type, rather than that type now being obsolete.
    Last edited by jabe; 19-10-2016, 02:01 AM.

    Leave a comment:


  • SimonN
    replied
    MATCH_ODDS_UNMANAGED still used? Depricated?

    Made AJAX call using to Visualiser to ListMarketTypes with 'Market Types' set to 'MATCH_ODDS_UNMANAGED' only and nothing returned?

    Surely, it can't just be there as a reference code only when there happens to be some events currently using it?

    Thank you

    Leave a comment:


  • LordRom
    replied
    forgot to thank BetDynamics.....

    Leave a comment:


  • jabe
    replied
    Originally posted by betdynamics View Post
    @jabe

    Why the confused smiley?

    If you just use turnInPlayEnabled (set to true) then it won't return any matches that are not due to go inplay - so it does not give you a FULL list of pre-kickoff matches (only that matches that will actually be turned inplay).

    In your case, you are only interested in inplay matches, so using turnInPlayEnabled works for you, but not for the generalised requirement for all pre-kick-off matches.
    Sorry, I think that was what confused me - I thought we were all talking about games that would be inplay and I picked up the impression that you were doing it a different (and maybe better) way.

    Leave a comment:


  • SimonN
    replied
    My thanks again to you, BetDynamics!

    Enumerating the full range of options as you have done, caused me to realise that what I had thought was my solution was not in fact my solution and that what I have needed is in fact what I thought I needed but couldnt at that time get to work.

    Namely:

    turnInPlayEnabled omitted / inPlayOnly = false
    All matches that are not yet started
    As you know from my earlier post you replied to for some reason I couldn't get that to work - it was still returning events even after starting.

    I really don't know what I was doing different but for some reason it is working now - with the double quotes - as you would imagine it should work as I had previously not been able to get to work:

    GetListEventsRequestString = "{""filter"":{""eventTypeIds"":[""" & EventTypeId & """],""inPlayOnly"":""false"",""textQuery"":""" & searchString & """}}"
    Great post enumerating all the possible options - should be pinned somewhere if not in the actual BF developers documentation, itself.

    Cheers, again.

    Si

    Leave a comment:


  • betdynamics
    replied
    @jabe

    Why the confused smiley?

    If you just use turnInPlayEnabled (set to true) then it won't return any matches that are not due to go inplay - so it does not give you a FULL list of pre-kickoff matches (only that matches that will actually be turned inplay).

    In your case, you are only interested in inplay matches, so using turnInPlayEnabled works for you, but not for the generalised requirement for all pre-kick-off matches.

    I think the summary is:

    turnInPlayEnabled = true / inPlayOnly omitted
    All matches that will go InPlay or are InPlay

    turnInPlayEnabled = true / inPlayOnly = true
    Only matches that have already started

    turnInPlayEnabled = true / inPlayOnly = false
    Matches that will go inplay but have not yet started


    turnInPlayEnabled = false / inPlayOnly omitted
    Only matches that will not go inplay

    turnInPlayEnabled = false / inPlayOnly = true
    No matches

    turnInPlayEanbled = false / inPlayOnly = false
    Only matches that will not go inplay


    turnInPlayEnabled omitted / inplayOnly omitted
    All matches (both inplay and not yet started)

    turnInPlayEnabled omitted / inPlayOnly = true
    All matches that are currently inplay

    turnInPlayEnabled omitted / inPlayOnly = false
    All matches that are not yet started

    Leave a comment:


  • jabe
    replied
    Good, glad you got it sorted and it helped me spot a problem in my code too, so thanks for that!

    One thing that's probably complicated my program is that I've spent a lot of time working on making it restartable so that if it fails or if I stop it to make a change during its (apparently unending!) development, I can restart it, and it loads much of the data from files.

    Leave a comment:

Working...
X