Don't allow an empty version_added

This commit is contained in:
Matt Martz 2019-02-28 16:37:38 -06:00 committed by Matt Clay
parent 8a02f894a6
commit 35f5ca8295

View file

@ -1418,7 +1418,8 @@ class ModuleValidator(Validator):
version_added = StrictVersion(
str(details.get('version_added', '0.0'))
)
except ValueError:
version_added.version
except (ValueError, AttributeError):
version_added = details.get('version_added', '0.0')
self.reporter.error(
path=self.object_path,