| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 22be96c commit f36614f
63 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -34,7 +34,7 @@ properly closed when you exit a ``with`` block: | |||
| 34 | 34 | .. code-block:: python | |
| 35 | 35 | ||
| 36 | 36 | with gitlab.Gitlab(host, token) as gl: | |
| 37 | - gl.projects.list() | ||
| 37 | + gl.statistics.get() | ||
| 38 | 38 | ||
| 39 | 39 | .. warning:: | |
| 40 | 40 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -158,7 +158,7 @@ with the GitLab server error message: | |||
| 158 | 158 | ||
| 159 | 159 | .. code-block:: python | |
| 160 | 160 | ||
| 161 | - >>> gl.projects.list(sort='invalid value') | ||
| 161 | + >>> gl.projects.list(get_all=True, sort='invalid value') | ||
| 162 | 162 | ... | |
| 163 | 163 | GitlabListError: 400: sort does not have a valid value | |
| 164 | 164 | ||
@@ -222,7 +222,7 @@ the value on the object is accepted: | |||
| 222 | 222 | ||
| 223 | 223 | .. code-block:: python | |
| 224 | 224 | ||
| 225 | - issues = project.issues.list(state='opened') | ||
| 225 | + issues = project.issues.list(get_all=True, state='opened') | ||
| 226 | 226 | for issue in issues: | |
| 227 | 227 | issue.my_super_awesome_feature_flag = "random_value" | |
| 228 | 228 | issue.save() | |
@@ -361,7 +361,7 @@ order options. At the time of writing, only ``order_by="id"`` works. | |||
| 361 | 361 | .. code-block:: python | |
| 362 | 362 | ||
| 363 | 363 | gl = gitlab.Gitlab(url, token, pagination="keyset", order_by="id", per_page=100) | |
| 364 | - gl.projects.list() | ||
| 364 | + gl.projects.list(get_all=True) | ||
| 365 | 365 | ||
| 366 | 366 | Reference: | |
| 367 | 367 | https://docs.gitlab.com/ce/api/README.html#keyset-based-pagination | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -13,7 +13,7 @@ It is likely that you used a ``MergeRequest``, ``GroupMergeRequest``, | |||
| 13 | 13 | can create a new ``ProjectMergeRequest`` or ``ProjectIssue`` object to | |
| 14 | 14 | apply changes. For example:: | |
| 15 | 15 | ||
| 16 | - issue = gl.issues.list()[0] | ||
| 16 | + issue = gl.issues.list(get_all=False)[0] | ||
| 17 | 17 | project = gl.projects.get(issue.project_id, lazy=True) | |
| 18 | 18 | editable_issue = project.issues.get(issue.iid, lazy=True) | |
| 19 | 19 | # you can now edit the object | |
@@ -58,7 +58,7 @@ To retrieve an object with all attributes, use a ``get()`` call. | |||
| 58 | 58 | ||
| 59 | 59 | Example with projects:: | |
| 60 | 60 | ||
| 61 | - for project in gl.projects.list(): | ||
| 61 | + for project in gl.projects.list(iterator=True): | ||
| 62 | 62 | # Retrieve project object with all attributes | |
| 63 | 63 | project = gl.projects.get(project.id) | |
| 64 | 64 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -32,8 +32,8 @@ Examples | |||
| 32 | 32 | ||
| 33 | 33 | List access requests from projects and groups:: | |
| 34 | 34 | ||
| 35 | - p_ars = project.accessrequests.list() | ||
| 36 | - g_ars = group.accessrequests.list() | ||
| 35 | + p_ars = project.accessrequests.list(get_all=True) | ||
| 36 | + g_ars = group.accessrequests.list(get_all=True) | ||
| 37 | 37 | ||
| 38 | 38 | Create an access request:: | |
| 39 | 39 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -18,7 +18,7 @@ Examples | |||
| 18 | 18 | ||
| 19 | 19 | List all OAuth applications:: | |
| 20 | 20 | ||
| 21 | - applications = gl.applications.list() | ||
| 21 | + applications = gl.applications.list(get_all=True) | ||
| 22 | 22 | ||
| 23 | 23 | Create an application:: | |
| 24 | 24 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -26,7 +26,7 @@ Examples | |||
| 26 | 26 | ||
| 27 | 27 | List badges:: | |
| 28 | 28 | ||
| 29 | - badges = group_or_project.badges.list() | ||
| 29 | + badges = group_or_project.badges.list(get_all=True) | ||
| 30 | 30 | ||
| 31 | 31 | Get a badge:: | |
| 32 | 32 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -32,7 +32,7 @@ Examples | |||
| 32 | 32 | Get the list of existing boards for a project or a group:: | |
| 33 | 33 | ||
| 34 | 34 | # item is a Project or a Group | |
| 35 | - boards = project_or_group.boards.list() | ||
| 35 | + boards = project_or_group.boards.list(get_all=True) | ||
| 36 | 36 | ||
| 37 | 37 | Get a single board for a project or a group:: | |
| 38 | 38 | ||
@@ -80,7 +80,7 @@ Examples | |||
| 80 | 80 | ||
| 81 | 81 | List the issue lists for a board:: | |
| 82 | 82 | ||
| 83 | - b_lists = board.lists.list() | ||
| 83 | + b_lists = board.lists.list(get_all=True) | ||
| 84 | 84 | ||
| 85 | 85 | Get a single list:: | |
| 86 | 86 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -18,7 +18,7 @@ Examples | |||
| 18 | 18 | ||
| 19 | 19 | Get the list of branches for a repository:: | |
| 20 | 20 | ||
| 21 | - branches = project.branches.list() | ||
| 21 | + branches = project.branches.list(get_all=True) | ||
| 22 | 22 | ||
| 23 | 23 | Get a single repository branch:: | |
| 24 | 24 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -55,19 +55,19 @@ Start a bulk import/migration of a group and wait for completion:: | |||
| 55 | 55 | ||
| 56 | 56 | List all migrations:: | |
| 57 | 57 | ||
| 58 | - gl.bulk_imports.list() | ||
| 58 | + gl.bulk_imports.list(get_all=True) | ||
| 59 | 59 | ||
| 60 | 60 | List the entities of all migrations:: | |
| 61 | 61 | ||
| 62 | - gl.bulk_import_entities.list() | ||
| 62 | + gl.bulk_import_entities.list(get_all=True) | ||
| 63 | 63 | ||
| 64 | 64 | Get a single migration by ID:: | |
| 65 | 65 | ||
| 66 | 66 | migration = gl.bulk_imports.get(123) | |
| 67 | 67 | ||
| 68 | 68 | List the entities of a single migration:: | |
| 69 | 69 | ||
| 70 | - entities = migration.entities.list() | ||
| 70 | + entities = migration.entities.list(get_all=True) | ||
| 71 | 71 | ||
| 72 | 72 | Get a single entity of a migration by ID:: | |
| 73 | 73 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -24,7 +24,7 @@ Examples | |||
| 24 | 24 | ||
| 25 | 25 | List cluster agents for a project:: | |
| 26 | 26 | ||
| 27 | - cluster_agents = project.cluster_agents.list() | ||
| 27 | + cluster_agents = project.cluster_agents.list(get_all=True) | ||
| 28 | 28 | ||
| 29 | 29 | Register a cluster agent with a project:: | |
| 30 | 30 | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments