<s> from nova . scheduler import filters <EOL> class TripleOCapabilitiesFilter ( filters . BaseHostFilter ) : <EOL> """<STR_LIT>""" <EOL> run_filter_once_per_request = True <EOL> def host_passes ( self , host_state , spec_obj ) : <EOL> host_node = host_state . stats . get ( '<STR_LIT>' ) <EOL> instance_node = spec_obj . scheduler_hints . get ( '<STR_LIT>' ) <EOL> if not instance_node : <EOL> return True <EOL> return host_node == instance_node [ <NUM_LIT:0> ] </s>
