Summer of Code/2010/Abstract Browser

From Sugar Labs
< Summer of Code‎ | 2010
Revision as of 13:17, 10 April 2010 by Lucian (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

About you

  • What is your name?

Lucian Branescu Mihaila

  • What is your email address?

lucian dot braneNOSPAMscu at gmail dot com

  • What is your Sugar Labs wiki username?

lucian

  • What is your IRC nickname?

lucian

  • What is your primary language? (We have mentors who speak multiple languages and can match you with one of them if you'd prefer.)

English and Romanian, either is fine.

  • Where are you located, and what hours do you tend to work? (We also try to match mentors by general time zone if possible.)

Mostly in the UK, perhaps a short while in Romania during the summer break.
I don't have a 'coding time' in my schedule, anything goes. I also often stay up late at night.

  • Have you participated in an open-source project before? If so, please send us URLs to your profile pages for those projects, or some other demonstration of the work that you have done in open-source. If not, why do you want to work on an open-source project this summer?

I've started a small project on freshmeat called statusPidgin that fetched text from various sources and made it a status message in Pidgin. It's now abandoned, but you can find the source on softpedia
I have also released one of my school projects as open source (a small web imap/pop3 client), but I doubt it's still hosted anywhere since there was little interest. You can get it from my dropbox. I haven't contributed in a significant way to open source projects before, beside bug reports and small patches.
I am a user of open source (linux, KDE, gcc, python, firefox, webkit) and am absolutely delighted by the concept. I am convinced it is the most efficient way of developing software, and perhaps not only software.
I am especially interested in the Sugar project, as I have myself experienced the closed-mindedness that schools instill in their students by teaching them using closed source software. I have been fortunate enough to get some exposure to linux and kde early enough and I would like to help others by showing them the alternatives. I have also participated on GSoC last year with Webified.

About your project

  • What is the name of your project?

AbstractBrowser

  • Describe your project in 10-20 sentences. What are you making? Who are you making it for, and why do they need it? What technologies (programming languages, etc.) will you be using?

Several people have expressed concern about xulrunner/hulahop and Browse maintainability. Also, there is a perception that webkit is faster and uses less memory than gecko. Various benchmarks do seem to show webkit to be superior, but results are inconclusive. Also, the Surf activity is significantly faster than Browse on XOs.

It would be good if Browse could switch between browser engines, if not at runtime at least with little effort. This would require an abstraction layer on top of hulahop/pywebkitgtk that Browse could target. This would open the road for other engines as well (like chromium).

Thus, this project has two parts:

  1. Design and implement a browser engine abstraction layer in Python with two backends: hulahop/xulrunner and pywebkitgtk/webkit.
  2. Port Browse to this new abstraction layer, complete with SSB support.

Since recent efforts to empower browsers like HTML5, Jetpack and the Chrome extension API are minimalistic in nature, the web development world is moving towards engine-independent extensions. Thus, implementing Jetpack/Chrome extensions/similar homegrown API for Browse should be both feasible and would benefit from a wealth of existing code.

SSBs are becoming less "web app to replace desktop apps" and more "internet apps to fit better in the desktop". I will design Browse's new SSB support to match this trend.

  • What is the timeline for development of your project? The Summer of Code work period is 7 weeks long, May 23 - August 10; tell us what you will be working on each week. (As the summer goes on, you and your mentor will adjust your schedule, but it's good to have a plan at the beginning so you have an idea of where you're headed.) Note that you should probably plan to have something "working and 90% done" by the midterm evaluation (July 6-13); the last steps always take longer than you think, and we will consider cancelling projects which are not mostly working by then.

Weeks:

  1. Write prototype of abstraction layer
    • WebView GTK widget that wraps hulahop.WebView or pywebkitgtk.WebView
    • nothing more than WebView.load_uri()
  2. Simple Browser activity based on the abstraction layer
    • recycle code from Browse & Surf
    • implement missing functionality as needed
  3. Basic browser functionality
    • DOM access
    • html events mapped to gobject events
  4. More browser functionality
    • downloads, history
    • user stylesheets
    • browser settings (i.e. proxy)
  5. Port SSB code from Browse's ssb branch
    • create ssb
    • edit userstyles/usersheets
    • bookmarklets
  6. More functionality
  7. Polish
  • Convince us, in 5-15 sentences, that you will be able to successfully complete your project in the timeline you have described. This is usually where people describe their past experiences, credentials, prior projects, schoolwork, and that sort of thing, but be creative. Link to prior work or other resources as relevant.

Python is my favourite programming language and JavaScript is a close enough third. I have some experience with python and I've built various things, from small utilities to websites with it. My most interesting project was helping to port a scientific application from c++ and Qt3 to Python and Qt4. It involved writing some Pyrex as well. It was lovely to see just how much the code shrunk, while keeping the application itself just as speedy.

I have used JavaScript and HTML to build a small web game, Mousebuster (not online, get it from my dropbox). Although at first I did not like javascript at all, I quickly realised it's immense advantage: huge existing install base.

I also had some contact with C# and Java and have been thoroughly disappointed by their general lack of expressiveness. I did one small schoolwork in C#, that dealt with a database of students. Recently, I did another small schoolwork in Java, dealing with a cricket club. After finishing each, I was amazed at how much of my code was just boilerplate or fighting the type system, code that I wouldn't have had to write in a more dynamic language.

I also used various linux distros for several years, until last year. I got a macbook as a gift and broadcom drivers are still a mess, but that'll get fixed at some point. I found unix in general so intriguing that I set up a small home server with a 300mhz CPU. I put debian on it and used it for various purposes, from web hosting, file serving, distcc node to a router for my home.

Since I was using a lot of open source at home, I tried to push it in school as well. I managed to make students and teachers aware of GCC as a replacement for Borland C/C++, Mono and SharpDevelop as a replacement for the not-quite-free Visual Studio. With the help of a friend, I even managed to convince the head of school to install Ubuntu in one of the labs.

You and the community

  • If your project is successfully completed, what will its impact be on the Sugar Labs community? Give 3 answers, each 1-3 paragraphs in length. The first one should be yours. The other two should be answers from members of the Sugar Labs community, at least one of whom should be a Sugar Labs GSoC mentor. Provide email contact information for non-GSoC mentors.
  • What will you do if you get stuck on your project and your mentor isn't around?

Google, check sugarlabs/olpc forums/mailing lists/wikis. Ask on #sugar/mailing list. Ask other mentors and GSoC students or developers of related open source software.

  • How do you propose you will be keeping the community informed of your progress and any problems or questions you might have over the course of the project?

In the worst case scenario, just emails to my mentor and commits. IRC has proven itself time and again and I intend to proudly announce any advances made. I intend to set up a blog and use that as well. Identi.ca or Twitter may also prove useful.

Miscellaneous

My development environment with the small hack.
  • We want to make sure that you can set up a development environment before the summer starts. Please send us a link to a screenshot of your Sugar development environment with the following modification: when you hover over the XO-person icon in the middle of Home view, the drop-down text should have your email in place of "Restart." See the image on the right for an example. It's normal to need assistance with this, so please visit our IRC channel, #sugar on irc.freenode.net, and ask for help.

Picture to the right.

  • What is your t-shirt size? (Yes, we know Google asks for this already; humor us.)

M

  • Describe a great learning experience you had as a child.

The most important thing I ever learned was to never be certain of anything and to always be prepared for the worst.

  • Is there anything else we should have asked you or anything else that we should know that might make us like you or your project more?

Web technologies are remarkably flexible and it would be great to encourage students to play around with them.