Maybe someone can help me out here?
","upvoteCount":1,"answerCount":1,"acceptedAnswer":{"@type":"Answer","text":"@botkero this should already work with token.rotate(expires_at=\"2024-12-12\"). Please let us know if not!
See source:
\n
\n python-gitlab/gitlab/mixins.py\n
\n\n Line 668\n in\n 541a7e3\n
\n| \n | self, id: Union[str, int], expires_at: Optional[str] = None, **kwargs: Any | \n
-
|
Hi, I wanna rotate a project access token but with a custom But I'm not sure how to do in I tried following: >>> type(token) # for reference
<class 'gitlab.v4.objects.project_access_tokens.ProjectAccessToken'>
>>> token.rotate({"expires_at":"2024-12-12"})
Traceback (most recent call last):
File "<pyshell#41>", line 1, in <module>
token.rotate({"expires_at":"2024-12-12"})
TypeError: ObjectRotateMixin.rotate() takes 1 positional argument but 2 were givenMaybe someone can help me out here? |
Beta Was this translation helpful? Give feedback.
-
|
@botkero this should already work with See source: python-gitlab/gitlab/mixins.py Line 668 in 541a7e3 |
Beta Was this translation helpful? Give feedback.
@botkero this should already work with
token.rotate(expires_at="2024-12-12"). Please let us know if not!See source:
python-gitlab/gitlab/mixins.py
Line 668 in 541a7e3