def is_valid_id(id):
 parts = id.split(':')
 if (len(parts) == 3):
  (group, artifact, version) = parts
  if (group and artifact and version):
   return True
 return False

def is_valid_id ( id ) : parts = id . split ( ':' ) if ( len ( parts ) == 3 ) : ( group , artifact , version ) = parts if ( group and artifact and version ) : return True return False
check if id is valid .