From bbf02c7ee3ae4ccb44fd70aab52a4cb3e7e29c68 Mon Sep 17 00:00:00 2001 From: Ray Date: Sun, 2 Aug 2009 23:50:44 -0400 Subject: [PATCH] Added correct cp1252 symbols for Euros and GBP. --- pyfpdb/PokerStarsToFpdb.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pyfpdb/PokerStarsToFpdb.py b/pyfpdb/PokerStarsToFpdb.py index 7f746e9e..fcfecb84 100755 --- a/pyfpdb/PokerStarsToFpdb.py +++ b/pyfpdb/PokerStarsToFpdb.py @@ -30,10 +30,10 @@ class PokerStars(HandHistoryConverter): # Class Variables mixes = { 'HORSE': 'horse', '8-Game': '8game', 'HOSE': 'hose'} # Legal mixed games - sym = {'USD': "\$", 'CAD': "\$", 'T$': ""} # ADD Euro, Sterling, etc HERE + sym = {'USD': "\$", 'CAD': "\$", 'T$': "", "EUR": "\x80", "GBP": "\xa3"} # ADD Euro, Sterling, etc HERE substitutions = { 'LEGAL_ISO' : "USD|EUR|GBP|CAD", # legal ISO currency codes - 'LS' : "\$" # legal currency symbols ADD Euro, Sterling, etc HERE + 'LS' : "\$|\x80|\xa3" # legal currency symbols ADD Euro, Sterling, etc HERE } # Static regexes @@ -50,7 +50,7 @@ class PokerStars(HandHistoryConverter): (-\sLevel\s(?P[IVXLC]+)\s)? \(? # open paren of the stakes (?P%(LS)s|)? - (?P[.0-9]+)/%(LS)s? + (?P[.0-9]+)/(%(LS)s)? (?P[.0-9]+) \s?(?P%(LEGAL_ISO)s)? \)\s-\s # close paren of the stakes @@ -60,7 +60,7 @@ class PokerStars(HandHistoryConverter): re_PlayerInfo = re.compile(""" ^Seat\s(?P[0-9]+):\s (?P.*)\s - \(%(LS)s?(?P[.0-9]+)\sin\schips\)""" % substitutions, + \((%(LS)s)?(?P[.0-9]+)\sin\schips\)""" % substitutions, re.MULTILINE|re.VERBOSE) re_HandInfo = re.compile("""