From 713419ef4e606157cdde6c1445703c074b0575ea Mon Sep 17 00:00:00 2001 From: Bernie Hackett Date: Tue, 19 Mar 2019 10:54:36 -0700 Subject: [PATCH] PYTHON-1656 explain() uses server default verbosity (cherry picked from commit fe307058c8e7b7c1469c9487126d6d8f5bed28c0) --- pymongo/cursor.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pymongo/cursor.py b/pymongo/cursor.py index 6c45fb6d7..6e723bc5f 100644 --- a/pymongo/cursor.py +++ b/pymongo/cursor.py @@ -801,6 +801,13 @@ class Cursor(object): def explain(self): """Returns an explain plan record for this cursor. + .. note:: Starting with MongoDB 3.2 :meth:`explain` uses + the default verbosity mode of the `explain command + `_, + ``allPlansExecution``. To use a different verbosity use + :meth:`~pymongo.database.Database.command` to run the explain + command directly. + .. mongodoc:: explain """ c = self.clone()