UVM mid test reset sequencer invalid state

UVM cookbook mentions to stop_seqeunces() cautiously. And make sure sequencer/driver is in idle state. Is there a examle for that ?
How do I deal with a reset that arrives in the middle of the call to get_next_item? If the item is sucessfully “gotten” we want the reset process to call item_done on it (right?), if not, we don’t.

There’s an article called ‘On the fly reset’ that covers this topic in the June 2012 edition of Verification Horizons:

To summarize: What you’ll need to do here is to make the driver hardware reset aware and able to cope with requests from active sequencers by flushing them.