more tolerant parsing of module imports