Social Help for Sugar: Week 1

Hi all. This summer, I’m doing a GSoC project for sugarlabs. It’s called ‘Social Help for Sugar’. Essentially, I’ll be integrating the Discourse discussion platform with sugar. More details can be found in my application.

Anyway, the first week is past and I’ve been doing some work to get the project started. The first thing I did was to set up discourse locally. This was somewhat more difficult that I assumed it to be. The Discourse team doesn’t provide an official setup guide for local installation. Indeed, the only guides provided are for full-scale production application. And so, I was left with some outdated guides scattered all over the internet. I tried two of those, both resulted in failure. Then, after some desperate searching, I found this guide: and voila! Discourse was working. I never thought that deploying a simple rails app can be such a pain – the ruby ecosystem is confusing to say the least. Anyway, I’ve enabled admin as well however the automatic mailer isn’t working – smpt ports are blocked in my institute. I’ll find a way around it.

The next thing was make a standalone browser-like activity which will be used to browse the social help forum. This aspect of the project was discussed on the sugar mailing list when I was in the process of making my application. It was decided that having a separate activity was better than relying on the default browser. And so, I cloned the browse activity, made some small changes to it and now, we have a social-help activity.

The next part was to enable a global shortcut for the activity. I had to dig through the code to understand how to do this. This was done as well.

Then, I needed a method using which we could tell the social-help activity which url to launch when it opens. This, I had no idea how to do. So, I went to the IRC but couldn’t get a solution. So, I decided to make a DBus interface that would have a method to open a URL. So, I read a few tutorials on DBus and was going to start tinkering with it when, while taking another look at the code, I found that  there’s a parameter passed to the activity on its startup – a parameter that carries in it a URI to be opened! And, after feeling a little silly, I finally had a solution to launching the social-help activity to any given URI.

The next thing to do will be to create a bunch of topics regarding every major activity and to create a map between activities and discourse topics so that social-help can be launched to the appropriate discussion topic. Then, we’ll take a look at the problem of automatic log-in.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s