Open oleksandr-argus opened 8 months ago
Commit Message:
Title: Fix for Error Calling backup_progress()
and backup_complete()
Methods
Description:
This commit addresses the HTTP 404 error encountered when invoking the backup_progress()
and backup_complete()
methods due to an outdated endpoint.
Changes: Code Modification
def backup_jira(jira_client: JIRA) -> None:
try:
jira_client.backup(filename='test_backup.zip')
print(jira_client.backup_complete())
except JIRAError as e:
if e.status_code == 404:
print("Backup progress endpoint not found. Skipping backup progress check.")
else:
raise e # Raise the error if it's not a 404
if __name__ == '__main__':
jira = JIRA(server=JIRA_ENDPOINT, basic_auth=(JIRA_USER, JIRA_TOKEN))
backup_jira(jira_client=jira)
Resolution Approach:
backup_progress()
and backup_complete()
function as expected.Impact:
backup_progress()
and backup_complete()
methods, enhancing the reliability of the application.Note: Additional details such as the specific code changes made, test cases executed, and any potential side effects should be included in the commit message based on the project's guidelines and requirements.
Bug summary
When I call method backup_progress() or backupcomplete() I got an error: `response text = {"message":"null for uri: https://xxx.atlassian.net/rest/obm/1.0/getprogress?=17108468xxxxxx","status-code":404}` This endpoint seems to be outdated
I found old closed issue with same error https://github.com/pycontribs/jira/issues/646 But for some reason I get this error even it should be already fixed.
Is there an existing issue for this?
Jira Instance type
Jira Cloud (Hosted by Atlassian)
Jira instance version
No response
jira-python version
3.6.0
Python Interpreter version
3.12
Which operating systems have you used?
Reproduction steps
Stack trace
Expected behaviour
backup_complete() returns True or False
Additional Context
No response