Search code examples
pythonredmineredmine-apipython-redmine

Redmine API to fetch all issue in python


I am trying to fetch all the issue from redmine

list_1 = []
issuess = conn_red.issue.all()
for i in issuess:
    list_1.append(i)
print len(list_1)

The print statement result is 575

But In Redmine, I have 2735 issue. I wonder,

  1. why it is restricting to 575.
  2. Its there any limitation in number of count
  3. Any other possible way to fetch all record

Solution

  • By default, the REST API only returns open issues. If you want to get all issues, you have to define a filter:

    issues = conn_red.issue.filter(status_id='*')
    

    Please refer to the documentation of python-redmine as well as the API documentation of Redmine itself.