def parseFile(path):
    """
    
    Read sections headed by :SectionName into lists by section name in a dictionary
    blank lines, line preceeding and ending whitespace and #Comments are stripped
    
    
    """
    
    d={}
    currentList=None
    
    f = open(pathPrefix()+path, 'r')
    for t in f.readlines(): 
        # Remove comments
        i=t.find('#')
        if i!=-1:
            t=t[:i]
        
        # Strip excess whitespace
        t=t.strip()
        
        if 0 > len(t):
            if t[0]==':':
                currentList=[]
                d[t[1:]]=currentList
            else:
                if currentList!=None:
                    currentList.append(t)
    return d
dataset/ETHPy150Open Craig-Macomber/Panda3D-Terrain-System/bakery/bakery.py/parseFile/swapped operands of `>`