Python regex to get version numbers, including if the version number specifies a range such as 1.0-2.0 or >1.0