Good start. Some improvements and fixes to do:
*For the project importer form:* underscores and periods are allowed in github
repo names, so the validator needs to be updated for that.
The values for `open_status_names` and `closed_status_names` look like they
were copied from the Google Code importer. Update them to match github
value(s). `EnableVoting` was set for Google Code since there were 'star'
values that were converted to votes. I don't think Github has anything
similar, right? So let's not turn voting on the tracker then.
On comments, "originally posted by" should be at the top of the comment, rather
than the bottom. And all the "originally" lines should have the username be a
link to the user's page on github. (Google Code import does this, including a
check in case the user doesn't exist any more).
Got the following error when importing "rauhryan/huboard". Besides fixing this
particular issue, I wonder if we want a try/catch around the attachment
handling if we think that it potentially could have errors on other input that
we don't expect yet.
~~~~
File
"/home/dbrondsema/dbrondsema-1019/forge/ForgeImporters/forgeimporters/github/tracker.py",
line 50, in import_tool
self.process_fields(ticket, issue)
File
"/home/dbrondsema/dbrondsema-1019/forge/ForgeImporters/forgeimporters/github/tracker.py",
line 74, in process_fields
body, attachments = self._get_attachments(issue['body'])
File
"/home/dbrondsema/dbrondsema-1019/forge/ForgeImporters/forgeimporters/github/tracker.py",
line 132, in _get_attachments
found_matches = re.finditer(REGEXP, body, re.IGNORECASE)
File "/var/local/env-allura/lib64/python2.7/re.py", line 186, in finditer
return _compile(pattern, flags).finditer(string)
TypeError: expected string or buffer
~~~~
We should pull the `events_url` API and put all the status changes into
comments (formatted just like regular Allura ticket status change comments).
I'm pretty sure all the URLs we fetch from Github need to handle pagination, so
that all the tickets/comments/events are fetched.
http://developer.github.com/v3/#pagination
Github markdown has a few minor differences that we should try to convert.
I've created a new ticket [#6622] for it. We can tackle that later, once this
is ticket is done.
Like, [#6533] this should have a controller for importing onto existing
projects (it'll show up on the Import admin menu).
It looks like this branch includes commits from [#6533]. I want to make sure
this is easy to rebase & merge into master when we're done. Perhaps you want
to have just one branch for the github tickets you're working on? Not sure
what works best for your workflow. At any rate, if you can rebase when ever
you merge branches together, that'll help keep the commit chain simple and
ready for master.
---
** [tickets:#6535] Ticket import for github**
**Status:** in-progress
**Labels:** github import 42cc
**Created:** Wed Aug 07, 2013 10:05 PM UTC by Dave Brondsema
**Last Updated:** Fri Aug 30, 2013 12:21 PM UTC
**Owner:** nobody
Use the github api for issues
http://developer.github.com/v3/issues/#list-issues-for-a-repository to import
tickets into allura. You can use ForgeImporter's GoogleCodeTrackerImporter (at
time of writing, cj/6464 on the apache repo has the latest code for it) and
TracTicketImporter as reference.
Import all the fields & values possible, including comments, events (e.g.
status changes) and attachments. See the Google Code and Trac importers for
examples of setting up the custom fields as needed, and referencing the remote
users (keep the tickets & comments as anonymous and add identification with
link into the body).
---
Sent from sourceforge.net because [email protected] is subscribed
to https://sourceforge.net/p/allura/tickets/
To unsubscribe from further messages, a project admin can change settings at
https://sourceforge.net/p/allura/admin/tickets/options. Or, if this is a
mailing list, you can unsubscribe from the mailing list.