atlassian-python-api
atlassian-python-api copied to clipboard
[Bitbucket Server] Fork Repository for different project
Function fork_repository_new_project in bitbucket module is throwing error while trying to create.
Traceback (most recent call last):
File "venv\lib\site-packages\atlassian\rest_client.py", line 400, in raise_for_status
j.get("errorMessages", list()) + [k + ": " + v for k, v in j.get("errors", dict()).items()]
AttributeError: 'list' object has no attribute 'items'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "", line 1, in
data = bitbucket.fork_repository_new_project( project_key="PROJ1", repository_slug="repo1", new_repository_slug="rep02", new_project_key="PROJ2" )
This is working as expected but not the bitbucket.fork_repository_new_project("PROJ1", "repo1", "rep02","PROJ2")
The function signature is:
def fork_repository_new_project(self, project_key, repository_slug, new_project_key, new_repository_slug):
You should change the order of the last two arguments.
Thanks @Spacetown