Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit24c283f

Browse files
author
Gauvain Pocentek
committed
Deprecate Project.archive()
1 parent45adb6e commit24c283f

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

‎gitlab/objects.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1556,7 +1556,14 @@ def repository_contributors(self):
15561556
raise_error_from_response(r,GitlabListError)
15571557
returnr.json()
15581558

1559+
15591560
defarchive(self,sha=None,**kwargs):
1561+
warnings.warn("`archive` is deprecated, "
1562+
"use `repository_archive` instead",
1563+
DeprecationWarning)
1564+
returnself.repository_archive(path,ref_name,**kwargs)
1565+
1566+
defrepository_archive(self,sha=None,**kwargs):
15601567
"""Return a tarball of the repository.
15611568
15621569
Args:

‎tools/python_test.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,8 +152,8 @@
152152
assert(tree[0]['name']=='README.rst')
153153
blob=admin_project.repository_blob('master','README.rst')
154154
assert(blob=='Initial content')
155-
archive1=admin_project.archive()
156-
archive2=admin_project.archive('master')
155+
archive1=admin_project.repository_archive()
156+
archive2=admin_project.repository_archive('master')
157157
assert(archive1==archive2)
158158

159159
# labels

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp