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

Commitc3c3a91

Browse files
chore(objects): useself.encoded_id where could be a string
Updated a few remaining usages of `self.id` to use `self.encoded_id`where it could be a string value.
1 parent27e0742 commitc3c3a91

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

‎gitlab/v4/objects/groups.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ def transfer_project(self, project_id: int, **kwargs: Any) -> None:
9292
GitlabAuthenticationError: If authentication is not correct
9393
GitlabTransferProjectError: If the project could not be transferred
9494
"""
95-
path=f"/groups/{self.id}/projects/{project_id}"
95+
path=f"/groups/{self.encoded_id}/projects/{project_id}"
9696
self.manager.gitlab.http_post(path,**kwargs)
9797

9898
@cli.register_custom_action("Group", ("scope","search"))

‎gitlab/v4/objects/projects.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -441,7 +441,7 @@ def upload(
441441
withopen(filepath,"rb")asf:
442442
filedata=f.read()
443443

444-
url=f"/projects/{self.id}/uploads"
444+
url=f"/projects/{self.encoded_id}/uploads"
445445
file_info= {"file": (filename,filedata)}
446446
data=self.manager.gitlab.http_post(url,files=file_info)
447447

@@ -538,7 +538,7 @@ def transfer_project(self, to_namespace: str, **kwargs: Any) -> None:
538538
GitlabAuthenticationError: If authentication is not correct
539539
GitlabTransferProjectError: If the project could not be transferred
540540
"""
541-
path=f"/projects/{self.id}/transfer"
541+
path=f"/projects/{self.encoded_id}/transfer"
542542
self.manager.gitlab.http_put(
543543
path,post_data={"namespace":to_namespace},**kwargs
544544
)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp