Small change - note we should error check
This commit is contained in:
		
							parent
							
								
									315d010311
								
							
						
					
					
						commit
						6214131713
					
				| 
						 | 
					@ -86,7 +86,7 @@ class Everleaf(HandHistoryConverter):
 | 
				
			||||||
        self.rexx.compileRegexes()
 | 
					        self.rexx.compileRegexes()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def readSupportedGames(self):
 | 
					    def readSupportedGames(self):
 | 
				
			||||||
        pass
 | 
					        return [["ring", "hold", "nl"]]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def determineGameType(self):
 | 
					    def determineGameType(self):
 | 
				
			||||||
        # Cheating with this regex, only support nlhe at the moment
 | 
					        # Cheating with this regex, only support nlhe at the moment
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -151,7 +151,9 @@ class HandHistoryConverter:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    #####
 | 
					    #####
 | 
				
			||||||
    # These functions are parse actions that may be overridden by the inheriting class
 | 
					    # These functions are parse actions that may be overridden by the inheriting class
 | 
				
			||||||
    #
 | 
					    # This function should return a list of lists looking like:
 | 
				
			||||||
 | 
					    # return [["ring", "hold", "nl"], ["tour", "hold", "nl"]]
 | 
				
			||||||
 | 
					    # Showing all supported games limits and types
 | 
				
			||||||
    
 | 
					    
 | 
				
			||||||
    def readSupportedGames(self): abstract
 | 
					    def readSupportedGames(self): abstract
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
| 
						 | 
					@ -162,8 +162,9 @@ class Importer:
 | 
				
			||||||
            if(filter == "EverleafToFpdb"):
 | 
					            if(filter == "EverleafToFpdb"):
 | 
				
			||||||
                conv = EverleafToFpdb(self.config, file)
 | 
					                conv = EverleafToFpdb(self.config, file)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            conv.readSupportedGames() # Should this be done by HHC on init?
 | 
					            supp = conv.readSupportedGames() # Should this be done by HHC on init?
 | 
				
			||||||
            conv.determineGameType()
 | 
					            gt = conv.determineGameType()
 | 
				
			||||||
 | 
					            # TODO: Check that gt is in supp - error appropriately if not
 | 
				
			||||||
            conv.processFile()
 | 
					            conv.processFile()
 | 
				
			||||||
            if(conv.getStatus()):
 | 
					            if(conv.getStatus()):
 | 
				
			||||||
                (stored, duplicates, partial, errors, ttime) = self.import_fpdb_file(conv.getProcessedFile(ofile), site)
 | 
					                (stored, duplicates, partial, errors, ttime) = self.import_fpdb_file(conv.getProcessedFile(ofile), site)
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue
	
	Block a user