neosqlite.collection.query_helper.graph_lookup module

Python implementation of MongoDB $graphLookup aggregation stage.

neosqlite.collection.query_helper.graph_lookup.process_graph_lookup(docs_with_context: list[dict[str, Any]], spec: dict[str, Any], collection: Any, evaluator: Any) list[dict[str, Any]][source]

Python fallback implementation of $graphLookup.

Parameters:
  • docs_with_context – List of documents with context (__doc__, __root__)

  • spec – $graphLookup specification

  • collection – Current collection instance

  • evaluator – ExprEvaluator for expression evaluation

Returns:

Updated docs_with_context