def add_objective(self, expr, name=None, scope=None):
        if self._max_objectives > 0 and \
           len(self._objectives) >= self._max_objectives:
            self.parent.raise_exception("Can't add objective '%s'. Only %d"
                                        " objectives are allowed"
                                        % (expr, self._max_objectives),
                                        RuntimeError)
        expr = _remove_spaces(expr)
        if expr in self._objectives:
            self.parent.raise_exception("Trying to add objective '%s' to"
                                        " driver, but it's already there"
                                        % expr, AttributeError)
        if name is not None and name in self._objectives:
            self.parent.raise_exception("Trying to add objective '%s' to"
                                        " driver using name '%s', but name is"
                                        " already used" % (expr, name),
                                        AttributeError)

        scope = self._get_scope(scope)
        try:
            expreval = Objective(expr, scope)
        except Exception as err:
            self.parent.raise_exception(str(err), type(err))

        name = expr if name is None else name

        if IDriver.providedBy(self.parent):
            #expreval.activate(self.parent)
            self.parent.config_changed()

        self._objectives[name] = expreval
The feed should get deepcopied, so this method of filtering shouldnt
dataset/ETHPy150Open OpenMDAO/OpenMDAO-Framework/openmdao.main/src/openmdao/main/hasobjective.py/HasObjectives.add_objective--crossover with--dataset/ETHPy150Open tschellenbach/Stream-Framework/stream_framework/tests/feeds/base.py/TestBaseFeed.test_feed_filter_copy