decides whether the given attribute should be excluded from tracing or not
494727
def _filter_attribute(mcs, attribute_name, attribute_value):
        
        if attribute_name == '__module__':
            return True
        elif hasattr(attribute_value, '_trace_disable'):
            return True
        return False
310754
def exclude?(path)
      exclude.include?(path) ||
        exclude.include?(path.split(METHOD_SEPARATOR).first)
    end
210106
def exclude(*what):
    
    cls, attrs = _split_what(what)

    def exclude_(attribute, value):
        return value.__class__ not in cls and attribute not in attrs

    return exclude_
997769
private void excludeByFeatCount(IntIntDenseVector[][] counts) {
        for (int t=0; t<included.length; t++) {
            for (int c = 0; c < included[t].length; c++) {
                for (int k = 0; k < included[t][c].length; k++) {
                    boolean exclude = (counts[t][c].get(k) < prm.featCountCutoff);
                    if (exclude) {
                        included[t][c][k] = false;
                    }
                }
            }
        }
    }
121860
def _is_allowed(attr, *args):
    
    for backend in _get_backends():
        try:
            if getattr(backend, attr)(*args):
                return True
        except AttributeError:
            raise NotImplementedError("%s.%s.%s() not implemented" % (
                backend.__class__.__module__, backend.__class__.__name__, attr)
            )
    return False
537911
function(attrs, attrsToRemove) {
    _.forEach(attrs, function(val, key) {
      // shouldRemove is either an object or a boolean
      var shouldRemove = attrsToRemove[key];
      if (_.isUndefined(shouldRemove)) {
        return;
      }

      // Support nested object
      if (_.isPlainObject(val) && !_.isArray(val) && _.isPlainObject(shouldRemove)) {
        return this._removeExpandableAttributes(val, shouldRemove);
      }

      // Make sure attribute is an object
      // Strip all nested properties except for `_id`
      if (_.isPlainObject(attrs[key]) && shouldRemove) {
        attrs[key] = _.pick(attrs[key], ['_id']);
      }
    }.bind(this));
  }
926163
def removeDefaultAttributeValue(node, attribute):
    
    if not node.hasAttribute(attribute.name):
        return 0

    # differentiate between text and numeric values
    if isinstance(attribute.value, str):
        if node.getAttribute(attribute.name) == attribute.value:
            if (attribute.conditions is None) or attribute.conditions(node):
                node.removeAttribute(attribute.name)
                return 1
    else:
        nodeValue = SVGLength(node.getAttribute(attribute.name))
        if ((attribute.value is None)
                or ((nodeValue.value == attribute.value) and not (nodeValue.units == Unit.INVALID))):
            if ((attribute.units is None)
                    or (nodeValue.units == attribute.units)
                    or (isinstance(attribute.units, list) and nodeValue.units in attribute.units)):
                if (attribute.conditions is None) or attribute.conditions(node):
                    node.removeAttribute(attribute.name)
                    return 1

    return 0
1266290
def excluded(filename):
    
    basename = os.path.basename(filename)
    for pattern in options.exclude:
        if fnmatch(basename, pattern):
            # print basename, 'excluded because it matches', pattern
            return True
814741
@Nullable private static Attribute<TraceContext> getTraceContextAttributeOrWarnOnce() {
        final RequestContext ctx = getRequestContextOrWarnOnce();
        if (ctx == null) {
            return null;
        }
        return ctx.attr(TRACE_CONTEXT_KEY);
    }
1179794
def trace(self, *attributes):
        

        @wrapt.decorator
        def wrapper(wrapped, instance, args, kwargs):
            if self._trace_all:
                return wrapped(*args, **kwargs)

            handler = instance

            with tracer_stack_context():
                try:
                    self._apply_tracing(handler, list(attributes))

                    # Run the actual function.
                    result = wrapped(*args, **kwargs)

                    # if it has `add_done_callback` it's a Future,
                    # else, a normal method/function.
                    if callable(getattr(result, 'add_done_callback', None)):
                        callback = functools.partial(
                                self._finish_tracing_callback,
                                handler=handler)
                        result.add_done_callback(callback)
                    else:
                        self._finish_tracing(handler)

                except Exception as exc:
                    self._finish_tracing(handler, error=exc)
                    raise

            return result

        return wrapper
546638
def is_excluded(root, excludes):
    # type: (unicode, List[unicode]) -> bool
    
    for exclude in excludes:
        if fnmatch(root, exclude):
            return True
    return False
669544
@Deprecated
    protected void setTraceSpec(String s) {
        if (s != null) {
            TraceSpecification ts = new TraceSpecification(s, null, false);
            setTraceSpec(ts);
        }
    }
803947
def should_be_hidden_as_cause(exc):
    
    # reduced traceback in case of HasWrongType (instance_of checks)
    from valid8.validation_lib.types import HasWrongType, IsWrongType
    return isinstance(exc, (HasWrongType, IsWrongType))
1219441
def _is_excluded(self, path, dir_only):
        """"""

        return self.npatterns and self._match_excluded(path, self.npatterns)
771719
def should_exclude(type_or_instance, exclusion_list):
    
    if type_or_instance in exclusion_list: # Check class definition
        return True
    if type(type_or_instance) in exclusion_list: # Check instance type
        return True
    try:
        if type_or_instance.__class__ in exclusion_list: # Check instance class
            return True
    except:
        pass

    return False
515268
def removeIndexOnAttribute(self, attributeName):
        '''
            
        '''
        attributeName = attributeName.lower()
        if attributeName in self.otherAttributeIndexFunctions:
                del self.otherAttributeIndexFunctions[attributeName]
        if attributeName in self._otherAttributeIndexes:
                del self._otherAttributeIndexes[attributeName]
270239
private boolean scopeIncludesImplicitOrAttributeTypes(GraqlCompute query) {
        if (query.in().isEmpty()) return false;
        return query.in().stream().anyMatch(t -> {
            Label label = Label.of(t);
            SchemaConcept type = tx.getSchemaConcept(label);
            return (type != null && (type.isAttributeType() || type.isImplicit()));
        });
    }