- try:
- format_split = version_string.split(' ')
- format, version = format_split[0].lower(), format_split[1]
- except:
- self.logger.info("RSpecVersion: invalid rspec version string: %s , using default" \
- % version_string)
- # invalid format. Just continue
- format, version = DEFAULT_FORMAT, DEFAULT_VERSION_NUMBER
-
- self.format = format
- self.version = version
+ format_split = version_string.split(' ')
+ try: self.format = format_split[0].lower()
+ except: pass
+ try: self.version = format_split[1]
+ except: pass