summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Wittig <max.wittig@siemens.com>2020-03-09 16:33:55 +0100
committerGitHub <noreply@github.com>2020-03-09 16:33:55 +0100
commit6f843b63f7227ee3d338724d49b3ce111366a738 (patch)
tree8efdae1001ea821425861ad9419f8e86201f2729
parent6c5458a3bfc3208ad2d7cc40e1747f7715abe449 (diff)
downloadgitlab-6f843b63f7227ee3d338724d49b3ce111366a738.tar.gz
Revert "feat: use keyset pagination by default for `all=True`"
-rw-r--r--docs/api-usage.rst6
-rw-r--r--gitlab/__init__.py6
2 files changed, 1 insertions, 11 deletions
diff --git a/docs/api-usage.rst b/docs/api-usage.rst
index dac3997..764f294 100644
--- a/docs/api-usage.rst
+++ b/docs/api-usage.rst
@@ -204,11 +204,6 @@ listing methods support the ``page`` and ``per_page`` parameters:
By default GitLab does not return the complete list of items. Use the ``all``
parameter to get all the items when using listing methods:
-.. warning::
-
- The all=True option uses keyset pagination by default if order_by is not supplied,
- or if order_by="id".
-
.. code-block:: python
all_groups = gl.groups.list(all=True)
@@ -408,3 +403,4 @@ parameter to that API invocation:
gl = gitlab.gitlab(url, token, api_version=4)
gl.projects.import_github(ACCESS_TOKEN, 123456, "root", timeout=120.0)
+
diff --git a/gitlab/__init__.py b/gitlab/__init__.py
index eed1ec1..8c78866 100644
--- a/gitlab/__init__.py
+++ b/gitlab/__init__.py
@@ -641,12 +641,6 @@ class Gitlab(object):
get_all = kwargs.pop("all", False)
url = self._build_url(path)
- # use keyset pagination automatically, if all=True
- order_by = kwargs.get("order_by")
- if get_all and (not order_by or order_by == "id"):
- kwargs["pagination"] = "keyset"
- kwargs["order_by"] = "id"
-
if get_all is True and as_list is True:
return list(GitlabList(self, url, query_data, **kwargs))