diff --git a/pyfpdb/PokerStarsToFpdb.py b/pyfpdb/PokerStarsToFpdb.py index 55ad9a37..39203430 100644 --- a/pyfpdb/PokerStarsToFpdb.py +++ b/pyfpdb/PokerStarsToFpdb.py @@ -37,6 +37,8 @@ class PokerStars(HandHistoryConverter): filetype = "text" codepage = ("utf8", "cp1252") siteId = 2 # Needs to match id entry in Sites database + + mixes = { 'HORSE': 'horse', '8-Game': '8game', 'HOSE': 'hose', 'Mixed Hold\'em': 'mholdem'} # Legal mixed games sym = {'USD': "\$", 'CAD': "\$", 'T$': "", "EUR": "\xe2\x82\xac", "GBP": "\xa3", "play": ""} # ADD Euro, Sterling, etc HERE substitutions = { 'LEGAL_ISO' : "USD|EUR|GBP|CAD|FPP", # legal ISO currency codes @@ -78,15 +80,6 @@ class PokerStars(HandHistoryConverter): 'Single Draw 2-7 Lowball' : ('draw','27_1draw'), '5 Card Draw' : ('draw','fivedraw') } - mixes = { - 'HORSE': 'horse', - '8-Game': '8game', - 'HOSE': 'hose', - 'Mixed PLH/PLO': 'plh_plo', - 'Mixed Omaha H/L': 'plo_lo', - "Mixed Hold'em": 'lh_nlh', - 'Triple Stud': '3stud' - } # Legal mixed games currencies = { u'€':'EUR', '$':'USD', '':'T$' } # Static regexes @@ -97,7 +90,7 @@ class PokerStars(HandHistoryConverter): # here's how I plan to use LS (?P(?P[%(LS)s\d\.]+)?\+?(?P[%(LS)s\d\.]+)?\+?(?P[%(LS)s\d\.]+)?\s?(?P%(LEGAL_ISO)s)?|Freeroll)\s+)? # close paren of tournament info - (?PHORSE|8\-Game|HOSE|Mixed Omaha H/L|Mixed Hold\'em|Mixed PLH/PLO|Triple Stud)?\s?\(? + (?PHORSE|8\-Game|HOSE|Mixed\sPLH/PLO|Mixed\sHold\'em)?\s?\(? (?PHold\'em|Razz|RAZZ|7\sCard\sStud|7\sCard\sStud\sHi/Lo|Omaha|Omaha\sHi/Lo|Badugi|Triple\sDraw\s2\-7\sLowball|Single\sDraw\s2\-7\sLowball|5\sCard\sDraw)\s (?PNo\sLimit|Limit|LIMIT|Pot\sLimit)\)?,?\s (-\s)? diff --git a/pyfpdb/TestHandsPlayers.py b/pyfpdb/TestHandsPlayers.py index 23859d9e..daaa4d71 100755 --- a/pyfpdb/TestHandsPlayers.py +++ b/pyfpdb/TestHandsPlayers.py @@ -152,7 +152,7 @@ def compare_hands_file(filename, importer, errors): # Delete unused data from hash del ghash['gsc'] del ghash['sc'] - del ghash['boards'] + del ghash['id'] for datum in ghash: #print "DEBUG: hand: '%s'" % datum try: @@ -161,12 +161,7 @@ def compare_hands_file(filename, importer, errors): pass else: # Stats don't match. - if (datum == "gametypeId" - or datum == 'sessionId' - or datum == 'tourneyId' - or datum == 'gameSessionId' - or datum == 'fileId' - or datum == 'runIt'): + if datum == "gametypeId" or datum == 'sessionId' or datum == 'tourneyId' or datum == 'gameSessionId': # Not an error. gametypeIds are dependent on the order added to the db. #print "DEBUG: Skipping mismatched gamtypeId" pass