Skip to content

Commit b1c6392

Browse files
author
Gauvain Pocentek
committed
Use the same description for **kwargs everywhere
1 parent 21e382b commit b1c6392

File tree

3 files changed

+32
-32
lines changed

3 files changed

+32
-32
lines changed

gitlab/__init__.py

+7-7
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ def http_request(self, verb, path, query_data={}, post_data=None,
407407
json)
408408
streamed (bool): Whether the data should be streamed
409409
files (dict): The files to send to the server
410-
**kwargs: Extra data to make the query (e.g. sudo, per_page, page)
410+
**kwargs: Extra options to send to the server (e.g. sudo)
411411
412412
Returns:
413413
A requests result object.
@@ -502,7 +502,7 @@ def http_get(self, path, query_data={}, streamed=False, **kwargs):
502502
'http://whatever/v4/api/projecs')
503503
query_data (dict): Data to send as query parameters
504504
streamed (bool): Whether the data should be streamed
505-
**kwargs: Extra data to make the query (e.g. sudo, per_page, page)
505+
**kwargs: Extra options to send to the server (e.g. sudo)
506506
507507
Returns:
508508
A requests result object is streamed is True or the content type is
@@ -532,8 +532,8 @@ def http_list(self, path, query_data={}, as_list=None, **kwargs):
532532
path (str): Path or full URL to query ('/projects' or
533533
'http://whatever/v4/api/projecs')
534534
query_data (dict): Data to send as query parameters
535-
**kwargs: Extra data to make the query (e.g. sudo, per_page, page,
536-
all)
535+
**kwargs: Extra options to send to the server (e.g. sudo, page,
536+
per_page)
537537
538538
Returns:
539539
list: A list of the objects returned by the server. If `as_list` is
@@ -575,7 +575,7 @@ def http_post(self, path, query_data={}, post_data={}, files=None,
575575
post_data (dict): Data to send in the body (will be converted to
576576
json)
577577
files (dict): The files to send to the server
578-
**kwargs: Extra data to make the query (e.g. sudo, per_page, page)
578+
**kwargs: Extra options to send to the server (e.g. sudo)
579579
580580
Returns:
581581
The parsed json returned by the server if json is return, else the
@@ -606,7 +606,7 @@ def http_put(self, path, query_data={}, post_data={}, files=None,
606606
post_data (dict): Data to send in the body (will be converted to
607607
json)
608608
files (dict): The files to send to the server
609-
**kwargs: Extra data to make the query (e.g. sudo, per_page, page)
609+
**kwargs: Extra options to send to the server (e.g. sudo)
610610
611611
Returns:
612612
The parsed json returned by the server.
@@ -629,7 +629,7 @@ def http_delete(self, path, **kwargs):
629629
Args:
630630
path (str): Path or full URL to query ('/projects' or
631631
'http://whatever/v4/api/projecs')
632-
**kwargs: Extra data to make the query (e.g. sudo, per_page, page)
632+
**kwargs: Extra options to send to the server (e.g. sudo)
633633
634634
Returns:
635635
The requests object.

gitlab/mixins.py

+7-7
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def get(self, id, lazy=False, **kwargs):
3232
lazy (bool): If True, don't request the server, but create a
3333
shallow object giving access to the managers. This is
3434
useful if you want to avoid useless calls to the API.
35-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
35+
**kwargs: Extra options to send to the server (e.g. sudo)
3636
3737
Returns:
3838
object: The generated RESTObject.
@@ -56,7 +56,7 @@ def get(self, id=None, **kwargs):
5656
"""Retrieve a single object.
5757
5858
Args:
59-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
59+
**kwargs: Extra options to send to the server (e.g. sudo)
6060
6161
Returns:
6262
object: The generated RESTObject
@@ -77,7 +77,7 @@ def refresh(self, **kwargs):
7777
"""Refresh a single object from server.
7878
7979
Args:
80-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
80+
**kwargs: Extra options to send to the server (e.g. sudo)
8181
8282
Returns None (updates the object)
8383
@@ -104,7 +104,7 @@ def list(self, **kwargs):
104104
page (int): ID of the page to return (starts with page 1)
105105
as_list (bool): If set to False and no pagination option is
106106
defined, return a generator instead of a list
107-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
107+
**kwargs: Extra options to send to the server (e.g. sudo)
108108
109109
Returns:
110110
list: The list of objects, or a generator if `as_list` is False
@@ -168,7 +168,7 @@ def create(self, data, **kwargs):
168168
Args:
169169
data (dict): parameters to send to the server to create the
170170
resource
171-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
171+
**kwargs: Extra options to send to the server (e.g. sudo)
172172
173173
Returns:
174174
RESTObject: a new instance of the managed object class built with
@@ -244,7 +244,7 @@ def update(self, id=None, new_data={}, **kwargs):
244244
Args:
245245
id: ID of the object to update (can be None if not required)
246246
new_data: the update data for the object
247-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
247+
**kwargs: Extra options to send to the server (e.g. sudo)
248248
249249
Returns:
250250
dict: The new object data (*not* a RESTObject)
@@ -313,7 +313,7 @@ def delete(self, id, **kwargs):
313313
314314
Args:
315315
id: ID of the object to delete
316-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
316+
**kwargs: Extra options to send to the server (e.g. sudo)
317317
318318
Raises:
319319
GitlabAuthenticationError: If authentication is not correct

gitlab/v4/objects.py

+18-18
Original file line numberDiff line numberDiff line change
@@ -227,7 +227,7 @@ def list(self, **kwargs):
227227
page (int): ID of the page to return (starts with page 1)
228228
as_list (bool): If set to False and no pagination option is
229229
defined, return a generator instead of a list
230-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
230+
**kwargs: Extra options to send to the server (e.g. sudo)
231231
232232
Returns:
233233
list: The list of objects, or a generator if `as_list` is False
@@ -430,7 +430,7 @@ def update(self, id=None, new_data={}, **kwargs):
430430
Args:
431431
id: ID of the object to update (can be None if not required)
432432
new_data: the update data for the object
433-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
433+
**kwargs: Extra options to send to the server (e.g. sudo)
434434
435435
Returns:
436436
dict: The new object data (*not* a RESTObject)
@@ -642,7 +642,7 @@ def create(self, data, **kwargs):
642642
Args:
643643
data (dict): Parameters to send to the server to create the
644644
resource
645-
**kwargs: Extra data to send to the Gitlab server (e.g. sudo)
645+
**kwargs: Extra options to send to the server (e.g. sudo)
646646
647647
Raises:
648648
GitlabAuthenticationError: If authentication is not correct
@@ -896,7 +896,7 @@ def add_ldap_group_link(self, cn, group_access, provider, **kwargs):
896896
group_access (int): Minimum access level for members of the LDAP
897897
group
898898
provider (str): LDAP provider for the LDAP group
899-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
899+
**kwargs: Extra options to send to the server (e.g. sudo)
900900
901901
Raises:
902902
GitlabAuthenticationError: If authentication is not correct
@@ -914,7 +914,7 @@ def delete_ldap_group_link(self, cn, provider=None, **kwargs):
914914
Args:
915915
cn (str): CN of the LDAP group
916916
provider (str): LDAP provider for the LDAP group
917-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
917+
**kwargs: Extra options to send to the server (e.g. sudo)
918918
919919
Raises:
920920
GitlabAuthenticationError: If authentication is not correct
@@ -932,7 +932,7 @@ def ldap_sync(self, **kwargs):
932932
"""Sync LDAP groups.
933933
934934
Args:
935-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
935+
**kwargs: Extra options to send to the server (e.g. sudo)
936936
937937
Raises:
938938
GitlabAuthenticationError: If authentication is not correct
@@ -1004,7 +1004,7 @@ def list(self, **kwargs):
10041004
page (int): ID of the page to return (starts with page 1)
10051005
as_list (bool): If set to False and no pagination option is
10061006
defined, return a generator instead of a list
1007-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
1007+
**kwargs: Extra options to send to the server (e.g. sudo)
10081008
10091009
Returns:
10101010
list: The list of objects, or a generator if `as_list` is False
@@ -1387,8 +1387,8 @@ def create(self, data, **kwargs):
13871387
Args:
13881388
data (dict): Parameters to send to the server to create the
13891389
resource
1390-
**kwargs: Extra data to send to the Gitlab server (e.g. sudo or
1391-
'ref_name', 'stage', 'name', 'all'.
1390+
**kwargs: Extra options to send to the server (e.g. sudo or
1391+
'ref_name', 'stage', 'name', 'all')
13921392
13931393
Raises:
13941394
GitlabAuthenticationError: If authentication is not correct
@@ -1736,7 +1736,7 @@ def create(self, data, **kwargs):
17361736
Args:
17371737
data (dict): parameters to send to the server to create the
17381738
resource
1739-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
1739+
**kwargs: Extra options to send to the server (e.g. sudo)
17401740
17411741
Returns:
17421742
RESTObject, RESTObject: The source and target issues
@@ -2303,7 +2303,7 @@ def delete(self, name, **kwargs):
23032303
23042304
Args:
23052305
name: The name of the label
2306-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2306+
**kwargs: Extra options to send to the server (e.g. sudo)
23072307
23082308
Raises:
23092309
GitlabAuthenticationError: If authentication is not correct
@@ -2376,7 +2376,7 @@ def get(self, file_path, ref, **kwargs):
23762376
Args:
23772377
file_path (str): Path of the file to retrieve
23782378
ref (str): Name of the branch, tag or commit
2379-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2379+
**kwargs: Extra options to send to the server (e.g. sudo)
23802380
23812381
Raises:
23822382
GitlabAuthenticationError: If authentication is not correct
@@ -2399,7 +2399,7 @@ def create(self, data, **kwargs):
23992399
Args:
24002400
data (dict): parameters to send to the server to create the
24012401
resource
2402-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2402+
**kwargs: Extra options to send to the server (e.g. sudo)
24032403
24042404
Returns:
24052405
RESTObject: a new instance of the managed object class built with
@@ -2424,7 +2424,7 @@ def update(self, file_path, new_data={}, **kwargs):
24242424
Args:
24252425
id: ID of the object to update (can be None if not required)
24262426
new_data: the update data for the object
2427-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2427+
**kwargs: Extra options to send to the server (e.g. sudo)
24282428
24292429
Returns:
24302430
dict: The new object data (*not* a RESTObject)
@@ -2451,7 +2451,7 @@ def delete(self, file_path, branch, commit_message, **kwargs):
24512451
file_path (str): Path of the file to remove
24522452
branch (str): Branch from which the file will be removed
24532453
commit_message (str): Commit message for the deletion
2454-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2454+
**kwargs: Extra options to send to the server (e.g. sudo)
24552455
24562456
Raises:
24572457
GitlabAuthenticationError: If authentication is not correct
@@ -2476,7 +2476,7 @@ def raw(self, file_path, ref, streamed=False, action=None, chunk_size=1024,
24762476
action (callable): Callable responsible of dealing with chunk of
24772477
data
24782478
chunk_size (int): Size of each chunk
2479-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2479+
**kwargs: Extra options to send to the server (e.g. sudo)
24802480
24812481
Raises:
24822482
GitlabAuthenticationError: If authentication is not correct
@@ -2849,7 +2849,7 @@ def get(self, id, **kwargs):
28492849
lazy (bool): If True, don't request the server, but create a
28502850
shallow object giving access to the managers. This is
28512851
useful if you want to avoid useless calls to the API.
2852-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2852+
**kwargs: Extra options to send to the server (e.g. sudo)
28532853
28542854
Returns:
28552855
object: The generated RESTObject.
@@ -2868,7 +2868,7 @@ def update(self, id=None, new_data={}, **kwargs):
28682868
Args:
28692869
id: ID of the object to update (can be None if not required)
28702870
new_data: the update data for the object
2871-
**kwargs: Extra options to send to the Gitlab server (e.g. sudo)
2871+
**kwargs: Extra options to send to the server (e.g. sudo)
28722872
28732873
Returns:
28742874
dict: The new object data (*not* a RESTObject)

0 commit comments

Comments
 (0)