[Qgis-psc] Attachment file types on issues

Richard Duivenvoorde richard at duif.net
Fri Nov 13 13:23:39 PST 2015


On 13-11-15 21:02, Richard Duivenvoorde wrote:
> On 13-11-15 19:51, Giovanni Manghi wrote:
>>> 1) create an empty repo
>>> 2) do a test import of the issues from redmine and see if the process generally goes well
>>
>> if someone with access to the Redmine server can download the issues
>> as described here
>>
>> https://github.com/IQSS/redmine2github#1-download-your-open-redmine-issues
>>
>> then I can try to give it a go.
> 
> Giovanni, I'll give it a go to download, keep you posted of results.


Mmm, enabled the REST api on redmin.
Got my redmine api key and github key
Tried both on the server itself, and on my local machine..

Without succes, need further deeper debugging to get this working...


python redmine_issue_downloader.py
Traceback (most recent call last):
  File "redmine_issue_downloader.py", line 294, in <module>
    rn = RedmineIssueDownloader(REDMINE_SERVER, REDMINE_API_KEY,
REDMINE_PROJECT_ID, REDMINE_ISSUES_DIRECTORY)
  File "redmine_issue_downloader.py", line 66, in __init__
    self.setup()
  File "redmine_issue_downloader.py", line 69, in setup
    self.connect_to_redmine()
  File "redmine_issue_downloader.py", line 76, in connect_to_redmine
    self.redmine_project =
self.redmine_conn.project.get(self.project_name_or_identifier)
  File
"/home/richard/z/15/redminemove/redmine2github/redmine_move/local/lib/python2.7/site-packages/redmine/managers.py",
line 117, in get
    return self.resource_class(self, self.retrieve()[0])
  File
"/home/richard/z/15/redminemove/redmine2github/redmine_move/local/lib/python2.7/site-packages/redmine/managers.py",
line 58, in retrieve
    response = self.redmine.request('get', self.url,
params=dict(self.params, limit=limit, offset=offset))
  File
"/home/richard/z/15/redminemove/redmine2github/redmine_move/local/lib/python2.7/site-packages/redmine/__init__.py",
line 100, in request
    raise UnknownError(response.status_code)
redmine.exceptions.UnknownError: Redmine returned unknown error with the
code 406
(redmine_move)richard at kwik~/z/15/redminemove/redmine2github/src/redmine_ticket
(master)$

url's like this work if you do projectname= quantum-gis/issues:

http://hub.qgis.org/projects/quantum-gis/issues.json?limit=100&key=xxx&offset=0

but fail with this error:

python redmine_issue_downloader.py
Traceback (most recent call last):
  File "redmine_issue_downloader.py", line 294, in <module>
    rn = RedmineIssueDownloader(REDMINE_SERVER, REDMINE_API_KEY,
REDMINE_PROJECT_ID, REDMINE_ISSUES_DIRECTORY)
  File "redmine_issue_downloader.py", line 66, in __init__
    self.setup()
  File "redmine_issue_downloader.py", line 69, in setup
    self.connect_to_redmine()
  File "redmine_issue_downloader.py", line 76, in connect_to_redmine
    self.redmine_project =
self.redmine_conn.project.get(self.project_name_or_identifier)
  File
"/home/richard/z/15/redminemove/redmine2github/redmine_move/local/lib/python2.7/site-packages/redmine/managers.py",
line 117, in get
    return self.resource_class(self, self.retrieve()[0])
  File
"/home/richard/z/15/redminemove/redmine2github/redmine_move/local/lib/python2.7/site-packages/redmine/managers.py",
line 61, in retrieve
    if isinstance(response[self.container], dict):
TypeError: list indices must be integers, not str

Regards,

Richard



More information about the Qgis-psc mailing list