MCPcopy Index your code
hub / github.com/django-haystack/django-haystack / run

Method run

haystack/backends/__init__.py:585–597  ·  view source on GitHub ↗

Builds and executes the query. Returns a list of search results.

(self, spelling_query=None, **kwargs)

Source from the content-addressed store, hash-verified

583 return kwargs
584
585 def run(self, spelling_query=None, **kwargs):
586 """Builds and executes the query. Returns a list of search results."""
587 final_query = self.build_query()
588 search_kwargs = self.build_params(spelling_query=spelling_query)
589
590 if kwargs:
591 search_kwargs.update(kwargs)
592
593 results = self.backend.search(final_query, **search_kwargs)
594 self._results = results.get("results", [])
595 self._hit_count = results.get("hits", 0)
596 self._facet_counts = self.post_process_facets(results)
597 self._spelling_suggestion = results.get("spelling_suggestion", None)
598
599 def run_mlt(self, **kwargs):
600 """

Callers 6

get_countMethod · 0.95
get_resultsMethod · 0.95
get_facet_countsMethod · 0.95
get_statsMethod · 0.95
test_get_spellingMethod · 0.45

Calls 6

build_queryMethod · 0.95
build_paramsMethod · 0.95
post_process_facetsMethod · 0.95
getMethod · 0.80
updateMethod · 0.45
searchMethod · 0.45

Tested by 1

test_get_spellingMethod · 0.36