Show
Ignore:
Timestamp:
05/01/09 18:41:31 (17 months ago)
Author:
confluence
Message:

comma escaping

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • confluence/genderiser/genderiser-python/genderiser.py

    r541 r548  
    6464 
    6565def splitlist(string): 
    66     return [x.strip() for x in string.split(",")] 
     66    string = string.replace("\,", "|") 
     67    chunks = [x.strip() for x in string.split(",")] 
     68    return [x.replace("|",",") for x in chunks] 
    6769 
    6870GENDERS = { 
     
    110112 
    111113# GET CONFIG 
    112 # TODO: how to escape commas?  CSV-esque format? 
    113114 
    114115conf = ConfigParser.ConfigParser()