Image of stick figure stumbling over rockYou may not be aware that I’ve created a teensy little StumbleUpon Safari extension. If not, go check it out. Apple supposedly has approved it for inclusion in their gallery, but I’ve checked and I don’t yet see it. Regardless, as the page says it is a minimally functional StumbleUpon Safari extension, only providing a few page redirects and using the badge API to query for the view count and page ID from their database. That’s all well and good but you can’t use it vote on things, and it offers no protection from iframe breakers. What’s a stumbler to do!?

Well, keeping in mind that this whole mess is SOLELY being developed because for whatever reason the powers that be at StumbleUpon.com have yet to develop their own Safari extension, I’ve been hacking around with their Firefox extension, reverse engineering it in order to do what needs doing in mine. It’s been fun and I’m making some headway but I’m not exactly sure when the next release will be. I have login capability working, but I haven’t yet tested doing anything useful once logged in.

One thing I’m a little concerned about is the fragility of what it is I’m doing. There is no official API for any of this. Assuming for a moment I actually manage to rip the guts out of the Firefox extension and make it work for Safari, there’s no guarantee the interface won’t change later on. They might alter the FF functionality such that it uses different calls. They might break some single interface that causes my whole little project to fall to pieces. Because there is no official StumbleUpon API, I have no guarantees that any of this will continue working. But, I’m enjoying doing this little bit of hackery and it seems like something useful.

I should mention too that the Firefox extension developers were thorough. I was thinking of something quick and dirty, but there are quite a few corner cases dealt with in the code and as I start bringing things over, I’m becoming torn as to whether to try to rewrite the few bits I want to pull in or try to port the entire back end over. The pain of missing those corner cases and coding for them myself or the pain of suffering through roadblock after roadblock of making Firefox extension-compatible Javascript work in a Safari extension environment. I’m leaning toward the former though the latter would, I think, be a more thorough implementation. I don’t doubt that the checks in the FF extension are necessary (like making sure to check for rapid clicking on the Stumble icon and not causing multiple async stumble requests), I may start off with a more fragile implementation in some respects, just to get it out there, followed by some touch up afterward to clean things up. I’ll be honest, I’m not doing this with my usual forethought, mostly because I think at some level I still see it as a “small” project.

Anyhow, I just figured I would mention what’s going on with it. Bear with me and mind the mess.