The invariantĀ
invariant(MatchExpression::AND == textFilterMe->matchType()) in planner_access.cpp apparently can be triggered and fail (see AF-1162). When it does, we should not crash the server, but rather return an error and provide some debug information, like serialise the filter or the whole text node in question.