The Boston Diaries

The ongoing saga of a programmer who doesn't live in Boston, nor does he even like Boston, but yet named his weblog/journal “The Boston Diaries.”

Go figure.

Tuesday, November 09, 2010

Stupid Twitter Tricks ][

Three years ago I did a Stupid Twitter Trick and it ran fine up until, until Twitter changed how third party applications can access Twitter. Then it went, well, not dark, but it wasn't exacty updating either.

Until this weekend. In fact, it wasn't that hard to update; perhaps an hour or so of work.

But three years though … perhaps I should come up with some other Stupid Twitter Trick to do; my quote file is running out of quotes.


Your ironic bug of the day

I'm working on some code to manipulate quote files (a simple text file filled with various quotes from people). It's not working—it either crashes or corrupts the output.

And it's the same quote each time—“There are only two hard problems in Computer Science: cache invalidation, naming things and off-by-one errors.”

The problem—an “off-by-one” error.

Tuesday, November 30, 2010

Lame excuses

Bunny and I were talking about the lack of posts around here, and I gave two rather pathetic reasons for slacking off. The second reason deals with The Corporation—I'm not sure how free I can be with work details. Smirk isn't my boss at The Corporation (he's a fellow cow-orker) and I haven't brought the issue up with R, who is The Ft. Lauderdale Office Manager (and the one who hired me initially) nor with E, who I do report to but works out of the Seattle Office.

Sure, I could mention that The Protocol Stack From Hell™ says it's thread safe, but still requires a mutex around a few calls. And I could mention that in the source code to The Protocol Stack From Hell™ we do have access to I found a global variable being used when creating a packet of data, thus causing all sorts of issues with the multithreaded testing tool I'm writing. I could also mention the fact that The Protocol Stack From Hell™ failed to properly use C++ inheritance by declaring multiple copies of object member variables in subclasses. And I could mention that we paid quite a lot of money to use this wonderful Protocol Stack From Hell™.

[Related to that—I could write about the wonderful Protocol Stack From Hell™ every day, but even I got tired of my rants against control panels. The Protocol Stack From Hell™ is way worse in that we don't have access to the source (well, we have access to some of the source; just not the stuff that's real puzzling) and it's only after browbeating the tech support that we learn just how bad the stuff really is, such as obtaining a textual representation of an error that's stored past a certain structure our code receives that's so totally not documented. And this is a daily occurrence! Don't even get me started on the silliness of their SNMP support!]

So yeah, I could mention all that, but I'm not sure if I can. Or should. You know?

The first reason I'm slacking off had Bunny rolling on the floor laughing, and yes, I could see her reasoning. It has to do with manually updating MyFaceSpaceBook everytime I posted here; it just feels like too much work.

Okay, there's nothing compelling me to link to my post at MyFaceSpaceBook, except that I personally view MyFaceSpaceBook as another feed (much like my Atom feed or RSS feed), and thus, I feel compelled to update MyFaceSpaceBook when I update here.

Okay, I'll wait until you stop laughing.

So, given that The Protocol Stack From Hell™ was acting up yesterday, I decided to see what it would take to automatically update MyFaceSpaceBook when I post here.

My God MyFaceSpaceBook doesn't make it easy.

All I want to do is update my status. After several hours of reading, registering as a developer (and man, I would link to that page, but now I can't even find the page—sheesh!), manually running API web calls (I didn't know about openssl / s_client -connect host:443 until tonight—wow!) to tweak settings in my account and learning curl (even though I've written code to retrieve web pages, it doesn't support HTTPS and that's a whole mess I'd rather skip for now), I have a proof-of-concept program that can update my status at MyFaceSpaceBook.

The next step is to integrate the proof-of-concept into the blog engine and have it update MyFaceSpaceBook automatically.

And then, maybe, I'll start posting more often.


I guess I can add “Facebook App Developer” to my résumé now …

I didn't expect my “proof-of-concept” to take as long to integrate into mod_blog as it did, and I do apologize to my friends on MyFaceSpaceBook who got spammed earlier today with, frankly, bizarre posts as I attempted to debug the new code. It's working, but there's still a worrying memory overwrite buried deep in the code that I've yet to fully squash (“fixing” a bug by reordering function calls is not a fix, but a temporary workaround).

But I have accomplished my goal of updating MyFaceSpaceBook automatically. It involved:

  1. Registering the application at MyFaceSpaceBook (you need to have a MyFaceSpaceBook account to see the page, otherwise I'd link to the page).
  2. Manually entering the appropriate URL (from the “User-Agent Flow” section) to give my “application” access to my MyFaceSpaceBook account.
  3. Manually entering another URL to give my “application” access to update the MyFaceSpaceBook status.
  4. Adding the code to authenticate as an application, which gives me the token required for the last step.
  5. And finally, adding the code to update my status.

The first three steps took several hours on the development site (which is horribly organized by the way—it's taken about an hour just to find the pages again for this post) and the last two took a couple of hours today to properly add the code (to add configuration options, pass in the actual status text, the final 10% of the code that tends to take 90% to finish).

And with luck, this will post properly.

I can only hope.

Obligatory Picture

[The future's so bright, I gotta wear shades]

Obligatory Contact Info

Obligatory Feeds

Obligatory Links

Obligatory Miscellaneous

You have my permission to link freely to any entry here. Go ahead, I won't bite. I promise.

The dates are the permanent links to that day's entries (or entry, if there is only one entry). The titles are the permanent links to that entry only. The format for the links are simple: Start with the base link for this site: https://boston.conman.org/, then add the date you are interested in, say 2000/08/01, so that would make the final URL:

https://boston.conman.org/2000/08/01

You can also specify the entire month by leaving off the day portion. You can even select an arbitrary portion of time.

You may also note subtle shading of the links and that's intentional: the “closer” the link is (relative to the page) the “brighter” it appears. It's an experiment in using color shading to denote the distance a link is from here. If you don't notice it, don't worry; it's not all that important.

It is assumed that every brand name, slogan, corporate name, symbol, design element, et cetera mentioned in these pages is a protected and/or trademarked entity, the sole property of its owner(s), and acknowledgement of this status is implied.

Copyright © 1999-2024 by Sean Conner. All Rights Reserved.