WeRelate talk:Software project

Watchers

Discussion Space [14 June 2012]

I don't know how many of us there are going to be, but I think that it might be useful to have a place for technical/development discussion. Like the Watercooler, but more technical?--Jdfoote1 15:02, 11 June 2012 (EDT)

I think so too. Once I post the source code on Github, we'll be able to use Github issues, which are nicely integrated into pull requests and milestones. What do you think about that? Perhaps we can use this talk page in the meantime?--Dallan 11:39, 12 June 2012 (EDT)
I think Github will work well, once there are specific projects to work on there. There's probably a need for somewhere on-wiki too, though -- at least somewhere to point to what dev work is going on, where to find things, etc.? Anyway, I'm just very excited that this is all happening! Thank you Dallan, for opening things up like this.  :-) — Sam Wilson ( TalkContribs ) … 20:44, 12 June 2012 (EDT)
Good point. A page here on WeRelate can serve as a directory of the various projects as you say. I've just renamed this page to Werelate:Software project, which I think can be the directory.--Dallan 23:45, 12 June 2012 (EDT)
I think that sounds good. - Jdfoote1 14:06, 14 June 2012 (EDT)

Printable WeRelate [15 June 2012]

(I'm almost embarrased to post this here, as the code is hardly a matter of pride, but no matter...) I've been tinkering with a system for exporting data from WeRelate and compiling GraphViz- and LaTeX-based charts and books, with the idea of being able to print them. I've stuck the code up on Github, if anyone's interested. The output is currently looking something like this and this:

An example of the GraphViz output of printable-werelate.
Enlarge
An example of the GraphViz output of printable-werelate.

I'm not even sure it's turning into the sort of thing I'm looking for, but as a prototype it's been interesting to think about.  :-) I'd rather like to recast the whole thing in Java...

Sam Wilson ( TalkContribs ) … 08:34, 13 June 2012 (EDT)

Wow - I think that looks fantastic - both the graph and the pdf document! Would you like to add them to WeRelate when I get the code out on Github?--Dallan 12:04, 13 June 2012 (EDT)
Oh, thank you!  :-) And yes, I'd love to add them to WeRelate. The traversal system needs a lot of improvement (it currently parses nodes more than once, for some lazy reason), but I'm very happy to work on that, and I'm sure you've got lots of stuff in place for doing that sort of thing anyway, which I can tie into. Should it be done in Java though? That's one thing I was pondering: making this a nice little app that people could download to run locally so that they'd get an offline copy of all the data they've put into WeRelate. — Sam Wilson ( TalkContribs ) … 20:01, 13 June 2012 (EDT)
I do have functions for reading graph-oriented data, which are currently used by the family tree link on person/family pages. I'd be happy to let you know what they are if you're interested.
Creating a downloadable app (using say Adobe AIR) could be a lot of work. What about running it on the server? I'm thinking it could run similarly to gedcom export -- run it as a php job, and leave a message on the user's talk page when the job is complete (or email the result to the user). Another option would be to run it as a java job -- either way works.--Dallan 23:19, 13 June 2012 (EDT)
Actually, I now remember that I decided not to do a standalone app!  :-) Mainly because of the GraphViz and LaTeX requirements (particularly the latter, which can be a pain to get on users' machines). So yes, I'll keep going with the PHP version, with the aim of running it on the server.
Could you send me whatever bits you think will be useful? If there's a separable chuck of code that deals with this stuff, could I just pull it in as a git submodule? Or maybe that'll have to wait till you've put the main code up. If so, I could just include it manually for now, and we can sort out integration later on.
I like the idea of a batch-jobbed system. That'll work well. Inputs similar to the page-compare page, I guess (two limited-length lists of people, one for descendents and one for ancestors)?
Sam Wilson ( TalkContribs ) … 20:44, 14 June 2012 (EDT)

I don't have anything easily separable right now, but here are some urls to get your started until I get the code put up:

These urls that are used by the family tree widget. They can be used to get the ancestors and/or descendants of a person or family. Hopefully I'll get the code put on github by the end of the month so you'll have more examples.

Right, the inputs could be similar to the page-compare page with two lists of people, or else similar to the "Trees" link on the left side of the Person pages.--Dallan 21:05, 15 June 2012 (EDT)


MediaWiki Bots [15 June 2012]

Do either of you have experience writing bots? I'm interested in working on the empty page deletion project. I saw Dallan's very helpful example code on GitHub, but I have zero experience in Java. I've looked into a few python libraries, but wanted to check with you guys before going any further.

First, Dallan, if you are going to be putting the scripts on the server, do they need to be in Java? I should probably start learning Java anyway...

If they can be written in python, do either of you know which library would be most appropriate?--Jdfoote1 14:18, 14 June 2012 (EDT)

No, I've only ever tinkered, and then only with wikis with API (which we'll have, after the upgrade). Lacking that, I guess it's a matter of doing things the old-fashioned way (pretending to be a web browser). Dallan will know more of course. I'd say you'll be fine with Python, though; most of the people I know (hmm, well, there's two) doing stuff with WMF projects are writing in Python. But we might have to wait till we've got the API?
Oh, and by all means, the empty-page-deletion project is yours for the taking.  :-) I'm going to keep playing with printable-werelate for the time being.
Sam Wilson ( TalkContribs ) … 20:44, 14 June 2012 (EDT)
Ah - is the MediaWiki API not set up? My quick look at the example code made me think that it was accessing the API, but maybe it's not? - Jdfoote1 11:44, 15 June 2012 (EDT)
That's right -- the MediaWiki API was added in a later version of MediaWiki than what I'm running. If you want to work on this before we've upgraded to the latest MediaWiki, you'll need to either learn java :-) or read through the java code I posted on github and port it to python. It is just a matter of pretending to be a browser as Sam says. Waiting isn't that bad of an option either.--Dallan 20:31, 15 June 2012 (EDT)
Ok. I still want to work on this, but it will be a longer-term thing than I hoped. :) What's the ETA for a new version of MediaWiki? -- Jdfoote1 20:49, 15 June 2012 (EDT)
I hope to have the code posted on github by the end of the month. It will likely take a couple of months after that to migrate to the latest version of mediawiki.--Dallan 21:07, 15 June 2012 (EDT)