def METHOD_NAME(fn):
    #open the xml file for reading:
    f = open(fn, 'r')
    data = f.read()
    f.close()
    #parse the xml you got from the file
    dom = parseString(data)
    #retrieve <tag>data</tag> that the parser finds with name tagName
    units = dom.getElementsByTagName('trans-unit')
    sources = {}
    targets = {}
    trans_units = {}
    id_list = []
    for unit in units:
        id = unit.getAttribute('id')
        source = unit.getElementsByTagName('source')[0].toxml()
        try:
            target = unit.getElementsByTagName('target')[0].toxml()
        except IndexError:
            target = ''
        sources[id] = source
        targets[id] = target
        trans_units[id] = unit
        id_list.append(id)
    return sources, targets, trans_units, id_list