def _update_trace(self):
        trace_db = None
        try:
            trace_db = trace_service.get_trace_db_by_trigger_instance(self.trigger_instance)
        except:
            LOG.exception('No Trace found for TriggerInstance %s.', self.trigger_instance.id)
            return None

        # This would signify some sort of coding error so assert.
        assert trace_db

        trace_db = trace_service.add_or_update_given_trace_db(
            trace_db=trace_db,
            rules=[
                trace_service.get_trace_component_for_rule(self.rule, self.trigger_instance)
            ])
        return vars(TraceContext(id_=str(trace_db.id), trace_tag=trace_db.trace_tag))
Iterative limited depth first search.
dataset/ETHPy150Open StackStorm/st2/st2reactor/st2reactor/rules/enforcer.py/RuleEnforcer._update_trace--crossover with--dataset/ETHPy150Open simpleai-team/simpleai/simpleai/search/traditional.py/iterative_limited_depth_first