Man this is fun!
I couldn't resist having a Titanic moment before heading out to he Bay.Sunday, August 19, 2007
Sailing Adventure: The Arrival
Sure, it may not look like much...but it's the crew that matters.
--Ben
Food Fact Of The Day
corn syrup.
Even Wikipedia confirms this:
http://wapedia.mobi/en/Special:Search?search=mincemeat&skl=Go&type=
Q: Why is this interesting?
A: Does everything I post here have to be interesting? It just is.
--Ben
Friday, August 17, 2007
Being The Environmentalist
It's probably an urban legend - but I'll be damned if I'm going to let a
bunch of defenseless fish and birds be strangled by this 6-pack 8-pack ring.
What an odd habit to have, that I feel responsible for cutting these up.
Do I take the bus to work, make sure I recycle at every possible chance
or bring my own bags to the super market? Nope, but I certainly won't
let a Coke 6 pack 8-pack ring pass me by.
Why is that? Probably marketing...
--Ben
Thursday, August 16, 2007
Custom Bugzilla Reports
I'm a big fan of Bugzilla and couldn't agree with more with Joel, a bug tracking system is an absolutely essential tool for making a successful dev team.
Where Bugzilla seems to be lacking the most is on the reporting side. I can cut them a bit of slack on this, as reporting needs are going to differ from team to team.
For a while now, my team has been tracking some items manually both in Bugzilla and on a Wiki page. Last week, I finally got fed up enough to do something about it.
So, this morning, Kelly and I decided to peek behind the curtain and actually look into querying Bugzilla's database directly to get the tidbits of info we needed from it.
I'm not quite sure what I was expecting - some sort of hideous, hacked up mess or something. But I was completely wrong. The Bugzilla MySQL database is pretty much exactly what you'd expect. It has a bugs table, products table, components table and lots of there tables exactly where you'd expect them. They are linked together by perfectly sane foreign keys.
In just a few minutes we had our first query written in PHP, and after an hour (with at least 10 minutes before the report was due), we had a working replacement for the report we had been working on manually.
Bugzilla even has a feature which seems custom made for querying stuff behind its back - keywords. Keywords are basically flickr/delicious style tags. You can add an arbitrary number of them to any bug report and then query against them later. Want to see all bugs that involved a problem with deployments - just tag them deployment and query for that after the fact. (Note: Tonya does our deployments, so we don't have bugs in this category.)
As an example, below is a query which will show all bug reports closed out in the last 7 days which have the tag foo.
SELECT b.bug_id, b.priority, b.resolution,
b.short_desc, p.name as product,
c.name as component, u.login_name as owner
FROM
bugs b, components c, products p,
keywords k, keyworddefs d, profiles u
WHERE b.bug_id = k.bug_id AND
k.keywordid = d.id AND
d.name = 'foo' AND
b.product_id = p.id AND
b.component_id = c.id AND
(b.bug_status = 'CLOSED' OR b.resolution <> '') AND
b.assigned_to = u.userid AND
b.lastdiffed > (now() - interval 7 day)
ORDER BY b.lastdiffed DESC
I just love the feeling of replacing manual effort with a script.
Eyes in the back of my head
I'm a big believer in moving people around for efficient communications. If two people have to work closely on something, even if only for a week or two, then, I think they should sit side by side.
As a result of this philosophy, we had yet another team office shuffle. My final placement is decent - I can see the door, and passers by can't see my monitor. Though I have folks sitting behind me.
With my wide angle mirror though I can at least get a glimpse of them back there. Theoretically, this would avoiding a heart attach if they tap me on the shoulder and I'm deep in flow.
Mostly I needed the mirror because they were laughing behind me and I needed to be sure they weren't also gesturing at me at the same time.
--Ben
Wednesday, August 15, 2007
On the difference between mostly sealed and sealed
Note to self: don't drop your mostly empty, mostly sealed, Tupperware container of Corn Chowder soup in your briefcase.
Unless of course you like the idea of your laptop, power cord and brief case having a pleasant Corn Chowder smell.
Luckily, I don't carry much in my briefcase and it's easy to clean.
--Ben
Digging Into Dune
I've always shied away from reading sci-fi. Even movies like Lord Of The Rings get me nervous - what with not only a cast of characters to learn, but different worlds and species as well. I took a chance though on Dune by Frank Herbert.
At first my concerns were well founded. There are 18 CDs in the book. It opens with an introduction of the cast - not single author - who will be acting out the book. Then the clincher - this is just Book 1 they tell me. Gulp. How many books are we talking about?
Things got scarier from there as quotes from an alien religious text is read and the story begins.
As I feared, new species, worlds, and concepts were being introduce by the minute.
I'm now on disk 6. I have to say that I absolutely love the book. I love it for the reasons I like most books: the characters are ones I like and can learn from and the storyline is quite interesting. There's enough action to keep my attention too.
The book clearly has a soap opera quality to it. Try this experiment one day when you are home sick - watch an episode of Days Of Our Lives. Within 3 minutes they will drop enough clues that you'll be totally up to speed. By the end of an episode, you'll be a pro.
Same with Dune. While the book invents new science, history, religion, politics, warcraft and entertainment for an alternate set of worlds and creatures it does so in a way that you can indeed follow along with.
I'm glad I took a chance on this one - it's already paid off.
--Ben
A Must Have Tech Support Tool
Microsoft Rocks!
A while back, I discovered the Windows XP Remote Assistance and my life of giving tech support advice to family and friends changed dramatically. All of a sudden, I had an easy way to get a view into what was on their screen. From giving HTML advice to figuring out why e-mail wasn't being downloaded, I was the Tech Support Man. All I lacked was the nifty headset phone and the possibly foreign accent.
However, I found that under some circumstances Remote Assistance wouldn't work. This was a major pain the neck because without a view into a family member's screen, debugging was reduced to "OK, read me exactly what's on the screen again" - not fun at all.
I finally dug into why I might be having issues with Remote Assistance - it turned out to be obvious. Remote assistance does nothing fancy to deal with routers and firewalls. I thought for sure Microsoft had a really sophisticated approach to dealing with giving support to customers on random home networks. Turns out, they don't support this in the least. When I actually looked into the contents of an invite that wasn't working, I found that the IP address listed to connect to was 192.168.1.18. Well, that's useless.
I could have tried to get around this by having the tech-suportee setup a rule on their router to forward requests from port 3389 to their computer, but please. If I can't explain to them how to fix their e-mail, then there's no way I'm going to be able to explain to them how to setup firewall rules on a random router interface, that of course, I can't see.
OK, Microsoft Doesn't Rock. Now What?
I was just about to gave up, I did one last Google search. Of course, LifeHacker to the rescue.
LifeHacker pointed me to ShowMyPC.com. This totally free service does exactly what I want. With the person on the phone, I have them click on the link labeled Show My PC to a remote user. They then click a button which gives them a unique password. On my side, I enter this password. Poof, a few seconds later, I'm staring at their desktop. All without a single thought about firewalls, NAT routing or a million other details.
No worrying about invitations, e-mail or hand generated passwords. It just works. This is my new preferred way to a share a desktop, hands down.
Tuesday, August 14, 2007
Introducing Ben's Scratch Pad
I've added a new piece to Ben's Journal - Ben's Scratch Pad. Folks will quickly recognize this as my twitter stream.
I've been thinking through twitter, trying to decide if it deserves a place in my publishing toolkit. On one hand, I really like how easy it is to publish with it. Quick thoughts, links, quotes and other small bits of content seem like better candidates for twitter than for my regular blog. Perhaps most importantly, the small format size should make my commitment of almost-daily posting an easier one to fulfill.
On the other hand, I didn't want to divide my already limited effort between two sites. I have enough trouble getting folks to read my blog - getting them to read my twitter stream seems like another big hurdle.
Then it hit me - I have total control over the benjisimon.blogspot.com. Rather than thinking of twitter as a secondary site, I decided to integrate into my existing site. You can't help read one without reading the other.
Now when I have a really busy day, and just have enough time to post a few snippets to twitter, my blog visitors will be treated to at least some fresh content. Mission accomplished. Almost.
What if you don't read my blog by visiting my website? What if you just read the feed. A quick Google search for feed splicing found this useful article on the topic. It turns out, Yahoo offers Pipes which among other things, glues together RSS feeds.
As a side note, Yahoo Pipes really is remarkable. It makes use of a graphical approach to composing feeds. In fact, it's the closest thing to a Graphical Programming Language that I've ever seen work. Check out my pipe here for an example.
The end result is I now have a new feed URL. Click here to subscribe to it. This feed allows you to simultaneously read both my Journal and my Scratch Pad at the same time.
SQL Brain Teaser - Why "an Incorrect datetime value"?
Kostyantyn ran into this issue today. I was totally clueless till he got it sorted out.
Suppose you have a table like so:
CREATE TABLEE foo(timevalue timestamp);
You successful run the following INSERT:
INSERT INTO foo(timevalue) values ('2007-03-11 01:53:44');
You attempt to run the following INSERT:
INSERT INTO foo(timevalue) values ('2007-03-11 02:53:44');
You get the error:
error# 1292: Incorrect datetime value: '2007-03-11 02:53:44' for column timevalue
What's the problem? How do you fix it?
The value 3/11/2007 corresponds to a daylight savings time switchover date. On that particular day, there was no 2:00 - 2:59am.
This is issue was caused by the fact that the database contained raw timestamp data from another timezone. When this data was loaded, the timezone wasn't adjusted to the locale specific timezone. The result was this one particular record which can't really exist.
Commute - Guessed Wrong Today
I'm sitting on 66 going 0 miles per hour. Looks like I guessed wrong on the right path to work today.
In past few days, I've been leaving at this same time and arriving at work in just over 23 minutes.
It's now 22 minutes into my commute and I've barely made it a few miles away from my house.
Argh. Nothing left to do but crawl forward when traffic starts up again and bail out of 66 as soon as possible.
Argh. Better blog rage than road rage.
--Ben
Scenes From A Sunrise
With Shira out of town, I was able to take a walk this morning at 6am'ish. While out, I caught some photos of the sunrise.
I can't remember the last time I watched the sun actually peak up over the horizon, so this turned out to be quite a treat. The Washington, D.C. skyline provided a nice backdrop for the whole event, too.
Monday, August 13, 2007
Windows XP - now as capable as FVWM 98
Back in college, I was a user of X-windows and the FVWM window manager. One of the neat features of this UI was the ability to support multiple desktops. This, of course, would freak people out when they scrolled from one desktop to another unexpectedly and "lost all your work," but once you got the hang of it, it was awesome.
It's now 9 years later, and I just setup my Windows XP box to behave this same way. This functionality has been around for some time, no doubt, but I guess I've never been motivated enough to actually hook set it up.
It turns out, it takes just minutes to get going. Here's what you do:
- Visit the Microsoft PowerToys page and download Deskman.exe
- Install it
- Now here's the tricky part - right click on the Task Bar thingy that runs along the bottom of the screen, and select toolbars, desktop manager. I say this is tricky because depending on where you click on the Task Bar you'll get a different menu, and this menu may or may not have a toolbars option.
- You can now click on the different desktop windows to switch between them
The real magic comes when you right mouse click on the MSVDM toolbar and select Configure Shortcut Keys. You'll want to pick key combinations that are easy to type. I've set my desktops as Control + Shift + J, Control + Shift + K, Control + Shift + L and Control + Shift + ;. Now I can easily hop between screens. Can you say boss key?
Virtual desktops aren't as nice as having multiple actual desktops, but it's certainly better than nothing.
For more info, check this article.
What other Windows Tools should I be installing?
Rethinking Return Values
The Problem
The other day I wanted to write a function in Scheme that did the following:
Function url-info takes in a URL and does the following. First it follows redirects till it either encounters a real page (response code is 200) or until it receives a server side error, such as a 404 or 500. If a real page is found, the value of the title tag is extracted. Both of the final URL and the value of the title are returned by this function.
For example, suppose I called url-info on http://tinyurl.com/39n5jb the result would be two values: http://benjisimon.blogspot.com and Ben Simon's Journal | ....
Writing this function in SISC is fairly trivial because you can leverage existing libraries like HTTPClient and HtmlParser that will do the heavy lifting. The question I was left with was simple - what should the interface to this function be?
The Java Solution
If I were coding this problem in Java, the answer to the interface question would be probably be:
public UrlInfo urlInfo(URL url) throws UrlInfoException {
// magic goes here
}
The UrlInfo object would be aPOJO with get methods for accessing the resolved URL and the title of the page. UrlInfoException would be a typical exception with methods to get the failed HTTP error code and a reason why it failed.
It's possible to write the Scheme function using the exact same pattern (return an info object, throw an exception). Before I did so, however, I wanted to resolve two nagging issues.
- Most of the time, when I get back the info object, the first thing I'm going to do is take it apart.
- The function is biased towards dealing with the successful case. You can definitely try/catch the exception and handle invalid URLs, but the code to do so is clunkier than the code that deals with a successful return value.
The Scheme Solution
After a bit of puzzling over this, I decided I would try a different approach in Scheme:
(url-info url success-handler failure-handler)
That is, you invoke url-info function not only with a URL to process, but two different functions. One function, the success-handler is invoked when the URL is processed correctly. The other handler, failure-handler is invoked when then URL can't be resolved.
What does url-info return? It returns whatever the handlers return. Here are some example uses of this function (quick Scheme lesson: (lambda (...) ...) is just like function(...) {...} is in JavaScript) :
;; Success: Just return the title of the page, upper cased,
;; throwing away resolved-url.
;; Failure: Throw an exception saying the call failed
(url-info url (lambda (resolved-url title)
(string-upcase title))
(error/f "Unable to resolve URL, reason: ~a (~a)"))
;; Success: make an info object for use later
;; Failure: make an error object for use later
(url-info url make-url-info make-url-error)
;; Success: raise an error
;; Failure: store the requested URL in a database
(url-info url (lambda (resolved-url title)
(error (format "Sorry, ~a already exists. Choose another."
resolved-url)))
(lambda (code reason)
(store-new-url! url)))
Here's what I like about this approach:
- The programmer is explicitly required to handle both the success and failure case. It's all too easy in Java to swallow, print out, or mis-handle an error case.
- Destructuring can happens automagically for you -- when the handlers are called, your arguments are taken apart for you.
- The url-info code doesn't need to worry about how it's going to be used. It's just as easy to use the failure case to get work done, as it is to use the success case.
- It is possible to create a library of handlers that are defined independently of the url-info package. One use for this might be to standardize error handling on a on a per-project basis.
- Converting this generic handler approach to the Java info object/exception approach is fairly painless. Yet other interesting patterns are available.
What's the down side? The major down side is that the nesting of different calls can get somewhat confusing, and this all breaks aways from the standard C like control flow so many developers are used to. However, given the fact that the above approach can be so powerful, I think the initial readability issue is a reasonable trade off.
I ended up implementing the handler style approach. So far, I'm liking how it works. However, we'll see in a few months if I still love it.
If you were writing this same function, what would you make the API?
Sunday, August 12, 2007
Diet Coke - The Hydrator?!
Here's the marketing text from a package of Diet Coke:
Research shows that all beverages contribute to proper hydration. That means whether it's your first can of the day or your afternoon pick-me-up, Diet Coke helps you stay hydrated all day long.
Talk about chutzpah! It's one thing for Coke to push Diet Coke as a drug distribution method, for "an afternoon pick me up." But to claim it's good for hydration, please.
And look how weak the claim is - "Research shows that all beverages contribute to proper hydration. " I see, so anything wet is good for hydration. I would imagine that Drinking Diet coke is only slightly more hydrating than drinking, say, motor oil. But whatever - it at least contributes to hydration.
My guess is that Diet Coke is making a statement against all those water snobs who claim that water is so pure and good for you. They are giving their drinkers just enough of an excuse to have them feel guilt free about ingesting this chemical concoction, instead of water. My guess is that sadly, it works.
Pardon me, I'm going to go have a hot fudge sundae for the calcium in the cream. It all contributes, you know.
--Ben
Diet Code - The Hydrator?!
"Research shows that all beverages contribute to proper hydration. That
means whether it's your first can of the day or your afternoon
pick-me-up, Diet Coke helps you stay hydrated all day long."
Talk about chutzpah! It's one thing for Coke to push Diet Coke as a
drug distribution method, for "an afternoon pick me up." But to claim
it's good for hydration, please.
And look how weak the claim is - "Research shows that all beverages
contribute to proper hydration. " I see, so anything wet is good for
hydration. I would imagine that Drinking Diet coke is only slightly
more hydrating than drinking, say, motor oil. But whatever - it at
least contributes to hydration.
My guess is that Diet Coke is making a statement against all those water
snobs who claim that water is so pure and good for you. They are giving
their drinkers just enough of an excuse to have them feel guilt free
about ingesting this chemical concoction, instead of water. My guess is
that sadly, it works.
Pardon me, I'm going to go have a hot fudge sundae for the calcium in
the cream. It all contributes, you know.
-Ben
--
Ben Simon
My blog: http://benjisimon.blogspot.com
Got a software idea? http://i2x.blogspot.com
Network Hacking Tool Of The Day
I just finished helping a friend get his home network setup. He's moving into a new place that's pre-wired with CAT5 almost everywhere (except the kitchen - kinda strange place to leave off). The cables all come into a box in the basement which has all sort of oddly labeled jacks. For example, what do you plug into the tap-A/modem slot?
Luckily, I had the right tool for this job. In this case it was a Ethernet cable tester which let us cut through the cable fog to reveal what really is connected to what.
Cable testers can be fairly expensive, though I managed to buy a cheap Chinese (or Japanese?) rip-off. I can't understand the manual, but the tester itself works like a champ. If you do get a tester make sure it splits into two pieces to test cables that have end points spread across a distance.
What a difference the right tool makes in getting the job done. Once we knew what connected to what, getting things plugged in was easy.
If you are handling Ethernet cable at all, this is a must have tool.
--Ben
Sunday Breakfast and UI Lesson
We busted out the waffle maker and Bisquick for a real Sunday breakfast. Even though we hadn't used the waffle maker in some time, the waffles still came out perfect. I attribute this to both Shira's cooking skills, and the waffle maker's UI.
Our waffle maker is the Macintosh mouse of kitchen appliances. It has a single light which represents the entire UI. No knobs, LCDs or dashboards. Just a light.
Plug in the waffle maker, light comes on telling you it's alive. Then it goes off when it's ready for use. You add batter, and the light comes on again. When the light goes off, it's time to eat.
I'm sure marketing was annoyed that the whole UI was driven by a single yellow lamp. But where's the color LCD? And what about the built in timer/radio, that our competitor has? Fortunately, elegant engineering won out here, and I had perfectly cooked waffles this morning without needing to consult a manual.
Lesson of the day - prefer simplicity and Doing The Right Thing over feature lists. Bonus lesson: add whip cream whenever possible.
For the record - the sausage links in the photo are Morning Star farms veggie sausage - very yummy stuff.
--Ben
Friday, August 10, 2007
Alarm System Annoyance
Apparently, our house is impenetrable by burglars - but is putty in the hands of gravity.
Curse you gravity! You're always causing things (like alarm sensors) to fall.
--Ben
Tip: Remembering to get your parking ticket validated
In the spirit of TipBin:
To remember to get your parking ticket validated at the super market, stick it in your wallet in front of your Visa card. When you go to pay, you'll have to take it out - reminding you to get it validated as you leave the store.
I just made-up/discovered this one while shopping at Harris Teeter.
Christian - I so need the mobile interface to TipBin. How's it coming? ;-)
--Ben
Here's a Tip - TipBin.com
My friend Christian recently finished coding a new web app - TipBin.com. It's a simple and cool concept - the site is a repository of brief tips.
The tips cover a wide variety of topics, from parenting to Linux administration (oh wait, maybe those topics aren't that different). Here's a sample:
Improve the growth of your tomato plants by placing a layer of red material such as plastic, cloth or mulch around the base of the plant. The red color reflects specific wavelengths of light that encourage the plants to grow, ripen and focus growth above ground instead of the root system. --rhall
The best part of TipBin is that it's so easy to contribute to. Once I worked up the courage to post one item, more ideas just started coming to me. As Christian says on the site - You know things that other people don't. So true.
It's actually amazing how much useful advice can be imparted in 320 characters.
Also, I have to say - Christian's wife, Michelle, is officially the tipmaster. She's got a tip for everything. Next time I need advice on anything, I'm going to her.
--Ben
Beamer's New Baby
Look at this proud father - holding his new 3G, Samsung Blackjack phone. Beamer even installed Google maps on it, so he was finally able to make it to work on time.
So, nu, when is he going to start a mobile blog? A Twitter stream?
This is quite an upgrade for Beamer - from an ancient Nokia 3120 candy bar style phone, with a whopping 4 lines of primitive text, to the top of the line.
Welcome to 2007 Beamer, glad to have you.
--Ben
Thursday, August 09, 2007
Definition: PMA
Shira mentioned to me that I've been using the word PMA without defining it for the world. Whoops.
PMA is an acronym for Positive Mental Attitude. It's a label assigned to anything which is designed to lift your spirits.
Sample usage:
After a day like that, you need some serious PMA. Check out these quotes for a healthy dose.
Teresa gets the credit for being the first person who used this phrasing around me.
Of course I love to blog about PMA. Check out all my PMA related posts here.
Contributing To An Open Source Project - Screencasting
I was poking around for Open Source project management tools when I came across activeCollab. On the front page is a introductory screencast, which takes you through the basics of the system.
The screencast is nice - but what really surprised me was that the coders on the project didn't produce it. A user (and no doubt, fan) of the system did.
What an excellent way to give back to a project. The screencast provided a nice balance between an advertisement and documentation for their tool. It inspired me to go to the next level and download it.
What a clever and valuable way to give back to a project.
RPM Fix - Lock table is out of available locker entries
I just noticed one of my servers was acting kind of sluggish. I ran an uptime and was greeted with:
[xxx@yyy zzzz]$ uptime 15:34:23 up 277 days, 2:14, 4 users, load average: 518.68, 196.46, 71.51
Holy smokes!
After killing a whole bunch of processes with:
sudo kill -9 `ps auxww|grep command-to-kill | awk '{print $2}'`
the system finally recovered. I thought I was out of the woods. But, when I went run an rpm -Uhv on a package I was greeted with this message:
[xxx@yyy zzz]$ sudo rpm -Uhv php-gd-5.2.3-5.i386.rpm rpmdb: Lock table is out of available locker entries error: cannot open Packages index using db3 - Cannot allocate memory (12) error: cannot open Packages database in /var/lib/rpm
D'oh. After a Google search, I found the fix to this problem here. Which boils down to:
rm /var/lib/rpm/__db.00* rpm --rebuilddb
The rebuild command took a minute or two to run. Then all was well again. Whew.
Review: Dave Barry's Money Secrets
I then took a break, and listened to a so-so FBI thriller.
With trepidation, I returned to the Dave Barry CD's. The 2nd disk was more palatable. By the 3rd disk I was laughing at every joke. It turned out to be terrifically funny.
While the book is supposed to be about money, Dave manages to cover pretty much whatever topic he wants to. His thoughts on buying a house, travel, and stock brokers are absolutely hilarious, among others.
Take his advice on estate planning. What's the most important issue with estate planning? Choosing your last words. This is key to have this planned out ahead of time, or you could really blow it. And the second most important? Thinking of outrageous requests to make your family fulfill with respect to how to dispose of your body.
I'm not quite sure why I had a near complete turn around with my appreciation for the book. Part of it may have been my mood at the time. Another big chunk may be related to the fact that this was a book on CD. Dave's humor is all about irony, and it may simply have taken some time for me to get use to the way the narrator delivered the text. My guess is that it is much trickier to voice a book that requires a near 100% sarcastic tone the the whole time, versus a typical novel which only requires small doses of this.
I give the book a 8.8/10.0 for being quite funny, even with a rough start.
--Ben
Wednesday, August 08, 2007
A Doctor's Visit Without The Alone Time
Tonight I visited a new doctor (nothing even remotely life threatening, promise) for the first time, and this is my lesson-learned-post. Notice anything that's missing?
The photo, of course.
I usually grab a snapshot of the office as I sit around and wait for doctor to make his or her appearance. I've even written entire blog posts while waiting for a doctor.
But not this evening.
First, let's take a step back. The doctor's office had me (read: Shira) download and fill out the lengthy history form at home. This is pure genius. I just walked in, handed her the form, and I was good to go. I hate arriving at a new office and spending 20 minutes trying to figure out what year I had may tonsils out, or if I'm supposed to check "no" on the pregnancy box or leave it blank.
When they did call, the nurse took me back to the room as usual. She collected a bit of info. Then, rather than disappearing like they usually do, she keyed in the info on a laptop right in the room. In fact, she never left the room. As a side note, she also didn't make me sit around in my skivvies or complain about how expensive a surgical table is, and then proceed to use the side of my face as one. But I digress.
The doctor then came in, and did his thing.
I have no pictures of the room, because I was never alone to snap one.
I find this most impressive.
There may be a few reasons for this policy. On one hand, the office was tiny, and this may just be a space saving device. Or maybe it was the end of the day, so they weren't busy. But, maybe, just maybe, someone realized that as technology advances, so can your customer service practices.
I didn't get a photo, but I did get a sense that someone actually cares about me. It's a fair trade, I guess.
My Vote: Yes On R6RS
I've been debating if it's appropriate to blog my reasoning for my vote yesterday morning on the latest Scheme standard. My decision was finally tipped by Will Farr, who did just this. As far as I can tell, nothing terrible has happened. (Right Will?)
I voted Yes. My comment, though not needed, was:
While there are some aspects of R5.97RS that I'm uncomfortable with, I think it's an overall step in the right direction. I'm confident that time will tell which aspects of the report need to be corrected, and that this will be done for R7RS.
Pretty cheesy, but what do you want for a message composed at 5:30am?
Overall, the standard is really good. I love that Unicode, syntax-case, libraries, byte level access and many other goodies were added. My first thought, like others, was that the core spec was too long, but after looking through it, I really don't think it is. Sure, the page count might be a bit high, but the core spec doesn't appear to have any obvious fluff to me.
So, what did I mean by aspects of R5.97RS that I'm uncomfortable with? Two things. First, I would have preferred to skinny down the standard library part of the report of the report. I would have been more comfortable with making chunks of it various SRFIs.
Currently, SRFIs provide libraries for lists, strings and dates. Why can't that same approach work for records, hashtables, and enumerations?
This strikes me as important because I'd like to see the standard stay as small as possible, and at the same time continue to grow the set of existing SRFIs. I think this is a real issue, because, as Java has shown, there's no limit to how large your standard library can grow. What happens when we want to add in stacks, queues, or more threading support? Does that go into the R7RS, or SRFIs?
The other point that was nagging me was that libraries aren't composable. I've come to really like Chez Scheme Modules, which provide basic control over namespace, yet can be composed together in interesting ways to provide more functionality. It seems more appropriate to provide a low-level, general purpose, feature like modules in the spec to me, rather than the heavier-weight library system.
After asking around, I learned that I'm essentially asking for are local libraries. Here's what the rationale document has to say on that topic:
Moreover it is debatable whether a top-level library should be the same construct as a local module. The job of the library system is to organize the top-level namespace, and not to serve as a target for expansion of sophisticated macros. Of course, the broader roles and syntactic similarity of module and library suggest merging the concepts, but merging the concepts further broadens the role of each. Such generalization may seem intuitively right to Scheme programmers, but all attempts by the editors at such broadening led away from consensus rather than toward it.
In other words, the drafters of the standard and I are on the same page - they just couldn't find a way to make it work. These are very smart folks, if they say they can't figure out a way to merge the concepts, then I believe them.
I'm pretty confident that by the time R7RS comes out, we'll either have figured out the solution to this problem, or will have decided that it's a non-problem altogether.
One final thought: vote yes, vote no, but whatever you do, just vote. Your vote is due Sunday, so get it in.
Tuesday, August 07, 2007
It's not the heat, it's the humidity
I see - it only feels like 101F degrees, it's really a nice cool 92F out there.
Looking outside my office window, I can almost see the humidity floating in the air. How typical for DC.
Shira and I have already started the discussions as to whether I can go for a run tonight outside or not, like I want to. So far, she's winning. Triple digits will do that.
Update: Here's a google talk session I just had with Shira on this topic:
Shira: "People don't realize it, but heat is generally the number-one killer" among weather-related causes, said Ben Miller, a meteorologist for the National Weather Service office in the St. Louis area. "We've gone all year without a serious heat wave so we want people to be aware of what to do to keep themselves safe."
Shira R. Simon is online.
Sent at 2:04 PM on Tuesday
Ben: tell it to the blog
Shira: I'm telling it to you
The weather forced the St. Louis Rams inside for daytime workouts this week.
Ben: it's well know that the St. Louis Rams are a bunch of chicks
Shira: with hand carts?
Sent at 2:10 PM on Tuesday
Ben: perhaps
Update: See, it's later in the evening and it's already cooling down. I have no idea what Shira's so concerned about.
Update: D'oh, we are going the wrong direction. What the heck kind of city has temperatures of 103F at 6pm?
My Twitter Theory
In The Beginning
Blogs have always served a pretty standard purpose: they are individual's publishing platforms. In the early days, they often gave voice to essentially whatever the author was thinking - from political ideas to what they had for lunch. Blogging also came with a novel addition - RSS. RSS allows you to follow dozens of Blogs all with minimal effort.
This combination of a publishing platform and a way to syndicate it, made for huge possibilities.
As the medium grew up, people realized that the more specialized your blog was, the better. Focus just on politics, gadgets or even random web findings, and leave off the stuff about your lunch, and you'll get more readers, revenue and respect.
Along comes Twitter which says that you can keep a blog in 140 character chunks. Do bloggers, who have been refining their craft for years, laugh them off the scene? Nope, they totally embrace them. And here's my theory as to why:
Twitter allows you to maintain an old-school-what-I-had-for-lunch blog alongside your profession, finely tuned one - all with a minimum of effort.
At a 140 characters a pop, Twitter allows you to satisfy your personal blog needs without a minimum of energy. Also, at this point, many blogger's have RSS feed lists that overwhelm them. Twitter comes along solves this by giving you to the option to skip RSS entirely, push the content directly to your readers.
Why do you need a personal blog at all? Well, that's probably another topic for another day. I'd say that the reasons range from: you want to keep Mom and Dad informed of your weekend plans, to having a place to publish your wacky theories.
So What?
Why do I need a theory on Twitter anyway?
- I'm trying to explain why smart people are so excited about Twitter.
- I think it explains why Twitter is less interesting to me personally - my blog is a variety show already, I don't need one on the side.
- If you considering starting a blog, you might want to start with Twitter. You can get all the benefits of a personal publishing platform in a package that couldn't be easier to keep updated.
Any suggestions for improving my theory (or is it a hypothesis? Can't remember which is which.)? Am I way off base?
Monday, August 06, 2007
Twitter As A Publication
Here's another perspective on twitter: it's a publication, not a communication tool. Interesting stuff.
I'm still not 100% sold on twittering as a useful addition to my blog. Though I'm going to keep it up a while longer.
Anybody out there finding it useful? Suggestions how to make it more so? I'm looking for friends to should follow, so let me know if you're a twitterer.
--Ben
Office Makeover
We put the team to work this evening to shuffle around Jade, Tonya and Chris' office.
I think the switch around was a success. The room feels way more open and light now.
Tonya - sorry in advance if you didn't want your desk in this position. It can all be undone.
--Ben
Before
After
Review: The Simpsons Movie
Last night Shira and I saw The Simpsons movie. I have to say, I wasn't that impressed. OK, it got me laughing a few times, and after sleeping on it, I've decided I liked the storyline.
Unfortunately, it just didn't compare to Simpsons during their hayday.
If you aren't a big Simpsons fan, I'd save my money on this movie and invest it in some DVD's of the classic seasons. (Anyone want to say in the comments what seasons are the classic ones?)
Still, it had enough jokes in it that I was still chuckling this morning, so it wasn't a total flop.
If you do see the film, make sure you hang out during the credits. There's at least one historical moment in there.
I give it a 7/10.
--Ben
Update: David thinks I'm full of crap and wouldn't know a good movie if it up and bit me. Well, he didn't quite say that, but check out the comments - he really liked the movie and explained why.
Update: My brother David had a different perspective on this, and really liked the movie. Check out the comments to see why.
Sunday, August 05, 2007
How To Win Friends and Influence People
Forgot all those self help books. Just buy a buffer and go around buffing out scratches for people. You'll be performing an act of magic.
That's what Justin's doing this afternoon. And I can tell you, he's earned my friendship for life.
(Well, he did so by being a nice guy. The buffer is just a bonus)
--Ben
Before
After
Jr. Assistant Associate Mechanic
I'm helping Justin put new brakes on his truck. My jobs: blogging the experience, giving moral support and pumping the brake pedal to release fluid.
Hey, pumping isn't as easy as it looks.
I even got a whiteboard hack out of this too. I used a whiteboard marker to track where the brake fluid was pre-draining. I could the erase and re-draw the line to track our progress.
We are mid process, so wish us luck.
--Ben
Friday, August 03, 2007
My Next Fridge
Forget fancy stainless steel appliances. And you can keep your internet accessing refrigerator.
Make my next fridge one covered in a whiteboard surface. How cool is that?
Thanks to Simon for sending the link my way.
Productivity Down, Life Good
A bit of excitement at the office, as a pretty nasty looking accident just happened outside our window.
This means that we have to stand at the window to watch the details unfold.
It also means that at as bad as my day may seem, it could be tons worse.
--Ben
Thursday, August 02, 2007
Hacker In Training
yet, and he told me no. Though, he may just be keeping it under an
assumed name.
And ladies, to my knowledge, he's not attached.
Shira and I are really enjoying baby sitting duty. The kids are being
fantastic. I know I was never this well behaved. Ever.
I have to say I'm dissapointed in Vtech, the creator of the laptop in
the photo. How could they not make the keyboard qwerty? And providing a
mouse instead of keyboard shortcuts. What kind of bad habits are you
instilling in America's youth?
--Ben
Battery Woes Solution #1 and a 1/2
partial "solution" came to mind.
Why don't I take an cell phone I have lying around stash it in my desk
or car? Then, when my Sidekick dies, I will simply grab the sim card
from it, and stick it in my backup phone. I should then be temporarily
back in business.
I'll be able to make calls and write short blog posts. Naturally,
these posts will almostly exclusively be about my sidekick's battery
life and the frustration it causes me.
At least I won't have that sense of dread that comes from being
disconnected. Of course, I'll also lose that odd calm and serentity
that comes from being disconnected. Oh well.
As for the 1/2 a solution to my battery life problem - I dimmed my
screen display.
It's 4pm and I'm at 3 bars - not great but better than yesterday.
I called T-mobile and spoke to a fellow in their Sidekick group. He
couldn't have been nicer. However, at the end of the conversation, all
he could do was sell me a $50.00 battery. I'm going to try to pick one
up cheaper on eBay (no doubt $1.00 for the battery, $49.99 for
shipping).
Mobile devices: the cause of, and the solution to, all of lifes
problems.
--Ben
Lunch Creativity
my veggie tex-mex meat like substance on, get this, wheat bread.
Some might say I've run out of things to bring to lunch.
I like to think of it as fusion cooking.
--Ben
Wednesday, August 01, 2007
Cell Phone Kvetching
At 4pm I noticed my battery was down to 1 bar. At 7pm tonight, I was completely out of juice.
This is unacceptable.
I charged the phone completely last night, and it can't make it through a full day of usage. It wasn't even particularly heavy usage.
I've officially changed my mind as to the biggest issue with the Sidekick III - it's no longer the camera, it's the battery life.
I totally have the urge to search eBay for a cheap phone with a qwerty keyboard that gets good battery life and would fulfill my basic needs: surfing basic web sites, posting to the blog, and of course the occasional phone call. (Does such a beast exist?) But inevitably, I'll just suck it up and go on with the SK III. I think I'll at least buy an extra adapter or two to keep at work or in the car.
Maybe it's time to buy a replacement battery?
--Ben
Postgres Xid Type Confusion
This morning I was trying to write a query against pg_locks but received this gem of a message:
ERROR: could not identify an ordering operator for type xid HINT: Use an explicit ordering operator or modify the query.
It even gave me a hint, and I still have no idea what the heck I'm supposed to do to fix it.
A Google search turned up this promising discussion. Unfortunately, it turned out to be a dead end, as the poster resolved his problem but I couldn't extract a solution from it.
I ended up looking for an alternate approach. From checking the postgres source code, I learned that an xid is output as a cstring. From Googling around, I learned that it's possible to convert cstrings to text by using the very handy function:
create or replace function any2text(anyelement) returns text as ' begin return $1; end; ' language plpgsql;
As the name suggests, the function above will convert any argument to text - not just xids.
With any2text I am now able to say any2text(transactionid) to convert this type as text. This means that, among other things, the group by clause can now work and my error above went away.
Warning: the above may in fact be a terrible idea. I'm not quite sure. I just know that it seems to work as advertised, and for my ad hoc queries was what I needed. I'd do a wee bit more research before I used this in a production system.



