Make python work for multiple dotted names