code: def collection_names(self, include_system_collections=True,
                           session=None):
          
          warnings.warn("collection_names is deprecated. Use "
                        "list_collection_names instead.",
                        DeprecationWarning, stacklevel=2)
          kws = {} if include_system_collections else _SYSTEM_FILTER
          return [result["name"]
                  for result in self.list_collections(session=session,
                                                      nameOnly=True, **kws)]
docs: **DEPRECATED**: Get a list of all the collection names in this
          database.
  
          :Parameters:
            - `include_system_collections` (optional): if ``False`` list
              will not include system collections (e.g ``system.indexes``)
            - `session` (optional): a
              :class:`~pymongo.client_session.ClientSession`.
  
          .. versionchanged:: 3.7
             Deprecated. Use :meth:`list_collection_names` instead.
  
          .. versionchanged:: 3.6
             Added ``session`` parameter.