#NEWLINE# def valid_characters( self ) : #NEWLINE# #INDENT# self . logger . info ( 'Check labels only use valid characters' ) #NEWLINE# for key in self . labels . keys ( ) : #NEWLINE# #INDENT# match = re . match ( '^[a-z0-9-.]+$' , key ) #NEWLINE# if ( not match ) : #NEWLINE# #INDENT# self . logger . error ( ( "Label '%s' must consist of lower-cased alphanumeric characters, dots and dashes" % key ) )