Cleaning phase of `FilterForm` is aimed to collect arguments for
        filtering (lookup parameters).

        As a result we will get three new artefacts:
          * return value: a mapping to use as keyword arguments in `filter`;
          * `complex_conditions`: a `Q` object to use as a positional argument;
          * `extra_conditions`: a mapping to use as keyword arguments in
            `extra`.

def clean(self):
        '''
        Cleaning phase of `FilterForm` is aimed to collect arguments for
        filtering (lookup parameters).

        As a result we will get three new artefacts:
          * return value: a mapping to use as keyword arguments in `filter`;
          * `complex_conditions`: a `Q` object to use as a positional argument;
          * `extra_conditions`: a mapping to use as keyword arguments in
            `extra`.
        '''
        simple_lookups = []
        complex_conditions = []
        extra_conditions = []
        for name, spec in self.filter_specs.iteritems():
            raw_value = self.cleaned_data.get(name)
            if isinstance(spec, RuntimeAwareFilterSpecMixin):
                lookup_or_condition = spec.to_lookup(raw_value, runtime_context=self.runtime_context)
            else:
                lookup_or_condition = spec.to_lookup(raw_value)

            if isinstance(lookup_or_condition, Q) and lookup_or_condition:
                    complex_conditions.append(lookup_or_condition)
            elif isinstance(lookup_or_condition, Extra):
                extra_conditions.append(lookup_or_condition)
            elif lookup_or_condition:
                simple_lookups.append(lookup_or_condition)

        self.simple_lookups = simple_lookups
        self.complex_conditions = complex_conditions
        self.extra_conditions = extra_conditions

        return {}