URI parsing is a pain