UVM Constrains inside a sequence are ignored

In reply to HelenLG:

Your contraint is in the wrong place. You have to use an inline constraint while randomizing the seq_item, like this

  virtual task body();
    `uvm_info(get_type_name(),$sformatf("Sequence randomize with %s", item.mode.name()), UVM_NONE)
    start_item(item); 
    if ( !item.randomize()with {item.mode == NORMAL_OP;})
      `uvm_error(get_type_name(), "Failed to randomize transaction")
    finish_item(item); 
    `uvm_info(get_type_name(),$sformatf("Sequence randomize with %s", item.mode.name()), UVM_NONE)
  endtask : body

Adding the constraint as a seperate constraint as you did is limited to the usage in the seq_item class.