Commits

wroh...@283d02a7-25f6-0310-bc7c-ecb5cbfe19da  committed 5173037

kajonggtest.py: fix csv comparison

when ordering csv rows by seed, use int(seed) instead of its string

  • Participants
  • Parent commits b577391

Comments (0)

Files changed (1)

File kajongg/src/kajonggtest.py

     for csvName in os.listdir('.'):
         if csvName.endswith('.csv'):
             games[csvName] = sorted(csv.reader(open(csvName,'r'), delimiter=';'),
-                key=lambda x : x[0])
+                key=lambda x : int(x[0]))
 
     if not games:
         return