Raise ValidationError if attribute type is missing

Change-Id: I92c88f6ee50183a6f2c36cf370dd4b15e56a227c
Fixes-Bug: 1386717