Portable Computing UI Redux: Editing Photos While Walking Downtown

One thing Instagram’s done for me (or to me): It’s made me much more prone to editing images on my phone. Which means I now have more data on the real-world equivalent of Charles Stross’ speculative incident in the beginning of Accelerando:

[Manfred is] standing in the plaza in front of the Centraal Station with his eyeballs [smart glasses that now seem like a prediction of Google Glasses] powered up…. The square smells of water and dirt and hot metal and the fart-laden exhaust fumes of cold catalytic converters; the bells of trams ding in the background, and birds flock overhead. He glances up and grabs a pigeon, crops the shot, and squirts it at his weblog to show he’s arrived. The bandwidth is good here, he realizes; and it’s not just the bandwidth, it’s the whole scene. (emphasis added)

I’ve written before about what the hell kind of UI he’s using to tell his systems to actually do all this stuff. One thing I noted was that, working on a modern smartphone, “Cropping is pretty much out of the question, although someone could write an app for it.” But that was two years ago, when I was using a Palm Pre… over 6 months before Instagram even launched their first product.

Fast-forward to this Monday. I was walking down Market Street and saw a statue that I felt like grabbing a picture of. I took the pic with my phone’s standard camera app. Then I decided, what the heck, why not post it on Instagram? When you import a photo from your Android Gallery into Instagram, it “gives you the opportunity” (i.e., forces you) to crop the image so it fits their 1:1 aspect ratio. While I was doing the cropping, I noticed: There was some text in there that was really kind of distracting. I wanted it out of there. Read More »

Is It Getting Better? Or Do You Feel the Same?

I don’t normally want to “harp on” gender issues in tech by doing two posts about them in a row, but I’ve gotta write about this while the news is still kind of current. In my last post, I wrote about the Geeklist fail and the Sqoot/Boston API Jam fail. At the end of my post, I wrote: “I think it’s getting better”. I mentioned that the reactions to those two fails had been much more feminist and progressive than previous ones I was aware of.

Since then, there have been two more incidents about gender and tech. And the first one is a near-perfect rebuke to Geeklist’s Sanz and Katz, who showed an almost textbook example of how not to respond to criticism. Chad Whitacre instead shows a pretty good example of how to do it right, and earns himself Geek Feminism Wiki’s “Cookie of the Week” award.

Testosterone Becomes assertEquals

Seven years ago, Whitacre created a testing framework for Python. It runs on the command line using curses[1]. When it came time to pick name for his testing framework, Whitacre decided on Testosterone and called it “the manly testing framework for Python”. Which was vaguely amusing, until his friend @velociraptors pointedly asked: “what, exactly, makes it manly?” There was a little bit of polite back-and-forth on Twitter, in which Whitacre tried to explain his reasoning.

He did not get offended, he did not condescend to her or get huffy… and after sleeping on it, he decided to change the name of his framework. He posted on Twitter saying, “Sorry for the sexism”, and then wrote an announcement and explanation of why he was renaming the software to assertEquals.

What She Really Said

The second item is Jessamyn Smith’s “What She Really Said” bot, designed to counter a “That’s What She Said” bot in her workplace’s IRC channel. This one is less of a total win, because honestly, she shouldn’t have had to write her bot at all. Her initial requests to co-workers to turn off the bot were met with the usual “It’s fun! You should lighten up!” dismissals. Read More »

What to Do When the Tech Failboat Sails

The tech world is no stranger to occasional outbreaks of Sexism!Fail, but the past two weeks have seen a rare double instance of it. Naturally, I’ve got to speak up. By the way, for anyone who missed the events, here are a pair of quick recaps:

And now, my responses to these items, and to some of the reporting surrounding them.

Get Mad, Make Noise

In both cases, the problems were flagged, and then ultimately stopped, because people spoke out about them and publicly called the sexists to task. In the second case, it took just one person speaking out to raise the ruckus that revealed Geeklist’s founders’ sexism and rampaging entitlement issues. In fact, their own issues were part of what made it so effective.

One point that hasn’t been addressed much is the insistent demands of Geeklist’s founders that Shanley Kane contact them privately instead of airing the issue on Twitter. If Ms. Kane had gone along with that, Sanz and Katz wouldn’t have had to listen to her at all. They wouldn’t have to worry about the fact that every entitled, arrogant response they made just dragged their public reputation further down into the gutter. They could have made their subtle, implied threats about her job in private, where nobody else could see how chillingly[1] creepy they[2] were. And when they were tired, they could have just shut down the conversation, with no consequences.

But Kane was smart enough not to fall into that trap. And besides, she was right: As she pointed out to them, their video was “in public and it merits a public response.” A public insult does not get to demand a private response. Once it’s out there on the public Internet, on the street… that’s where the conversation is. Read More »

Good Things About FizzBuzz

Over a year ago, I mentioned FizzBuzz as a basic competence screen during interviews. At the time, I said: “My only real quarrel with FizzBuzz is that, at this point, any developer worth their salt is familiar with it.” I seem to have been wrong, becuase I keep running into coders who definitely are competent, and who haven’t encountered it yet.

That’s fine, because FizzBuzz does have a few nice qualities as a test.

It’s Language-Agnostic

It makes sense for someone to code a FizzBuzz in anything from JavaScript to Haskell to C++ to Ruby to Python to assembler (pick your instruction set). The same cannot be said of various other standards, like “Reverse a string in-place” (which takes a bit of thought and care in C, and so makes a good test — but is utterly trivial in languages like Perl or PHP that have built-in string-reversal functions) or “connect to a webpage, count the frequency of words in it, and output them sorted in descending order” (which makes sense in scripting languages with well-known HTTP or cURL packages, but is far too big to make a decent whiteboard question in ones like C or C++).

It Doesn’t Require Memorization

There are some questions that require that the applicant knows a particular library call or special function. In the previous paragraph, I mentioned Perl’s reverse() and PHP’s strrev() — those aren’t what I mean, because those are pretty core functions. Those are the sort of thing anyone who does any text manipulation will have memorized, because they use it every day. But what about some of the more obscure ones, like PHP’s strncmp()? If you ask a question that requires it, you’re basically asking your applicant, “Have you heard of this really obscure function?” (In the case of languages like PHP, with its over-3,000 core-level functions, this is particularly evil, but the same results can be obtained by using a little-known CPAN package, C++ stdlib function, or Java Class Library function.)

FizzBuzz doesn’t require any weird functions to solve. It’s nothing but math, plus a for loop and an if/else. The most obscure thing in it is modulo arithmetic. And sure, maybe the applicant might have forgotten what the modulo operator is, because it’s not the sort of thing most people use every day.

But you can still solve it without the mod operator. Read More »

A Cute Motto Can’t Make Up For Evil Actions

I recognize that Google’s motto is not (the oft-misquoted) “Do no evil”. It’s the much easier-to-achieve mandate of “Don’t be evil”. But even that very low bar is one Google doesn’t seem to be hitting any more, and they don’t seem interested in trying to.

The latest “Google being evil” story, where it turns out they’ve been tricking Safari browsers into allowing tracking that they’re supposed to block, is by no means the only recent example. It’s just the one that’s gotten the most press — and a great place to start.

Part of the commotion is that the particular way that Google circumvented Safari’s privacy settings wound up completely undoing Safari’s privacy where Doubleclick was concerned. That’s the part Google didn’t really intend to do. But what they did intend to do was explicitly bypass Safari’s privacy settings, at least where their own +1 button was concerned. They wrote special-case code, served only to Safari browsers, which was designed to trick the browser into believing that the user was interacting with the +1 button — even though the user was doing no such thing.

This isn’t just something corporations do. Humans are complicit in it. Somewhere along the way, there was a Google engineer who was asked to write this code. He or she should have said, “Hey, doesn’t this sound kind of… well, evil?” Somewhere along the way, there was a Google product manager who was asked — or who independently decided — that tricking the browser and violating its privacy settings would be a good thing. Again, he or she should have said: “Wait a second, this is evil. We shouldn’t be doing this.

But this is not the only evil thing Google’s done in the past few months.

There’s also the way they helped sponsor this year’s CPAC, which gave prominent slots to white-power advocates and hate groups. And then there’s the recent privacy change, and their ridiculous cop-out on #NymWars, which disproportionately affects people whose voices are already too marginalized… and all that is on top of the stuff I posted about a year and a half ago, giving a litany of pretty evil things Google had done.

Around the same time, I posted a blog entry asking why Apple was still considered a “good guy” by geeks. At this point, I feel that question is much more appropriately directed at Google.

Google is no longer the happy, friendly company it once was. It is not a company I can support any more. I’m deleting my Google+ account, and looking for alternatives to Google Contacts and Calendar (which I’m really mostly using because of my Android smartphone). If you’re a geek who works for Google? Leave. Stop being a party to their evil. I know it takes a few months to find a job in Bay Area tech circles, but with Google on your résumé, you can surely find something.

But do it now. The way Google is burning out its reputation capital, in a few years having Google on your résumé may start to look like Microsoft did ten years ago… and then like having SCO on your résumé.

Beware of Optional Curly Braces — They Will Bite You

I was looking through some PHP code from a third-party vendor recently, and saw something that made my jaw drop. It’s pretty innocent-looking, at first. Here’s a somewhat anonymized and genericized version of the code, but the thing that bothered me is still intact. It’s not really a bug, per se; the code will function as intended. But…

$currentRow = 0;
$itemId = “”;
$index = 0;
while ($row = mysql_fetch_object($result)) {
     if ($currentRow == 10) {
          renderHeaderRow();
          $currentRow = 0;
     }
     // takes an itemId and displays relevant columns
     renderSummaryRow($row->itemId);
     $currentRow++;

     if ($index > 0)
          $itemId .= “,”; # interpolate a comma
     $itemId .= $row->itemId;
     $index++;
}

See the problem? Really, there are a few ways this can go wrong. To a quick glance, the only clue that line 14 (“interpolate a comma”) is part of a conditional is its indentation. The indentation is important to a human reader — but absolutely irrelevant to the PHP interpreter, which simply treats the next line after the conditional as the conditional’s block. Regardless of how it’s indented, and regardless of what else is around.

The way it looks to a human is not the way it looks to the machine.

What happens if someone wants to add some logging? What if they add it after the comma line?

if ($index > 0)
     $itemId .= “,”; # interpolate a comma
     writeLog(“Added a comma”);
$itemId .= $row->itemId;
$index++;

Now the log claims the code has added a comma, even when it hasn’t. But still, it could be worse! What if you decided to add your logging before the other line?

if ($index > 0)
     writeLog(“Adding a comma to itemId…”);
     $itemId .= “,”; # interpolate a comma
$itemId .= $row->itemId;
$index++;

Now it adds a comma no matter what — even the first time through the loop, when the string is empty. So instead of a string like '123,124,125', $itemId will now have a leading comma: ',123,124,125'. Since this value is getting stitched into a SQL query later on, it means your app will blow up with a SQL syntax error.

This is why Python makes whitespace significant to program flow. The way the indentation makes it look like the logical structure is, is how the structure actually is.

And this is also why Perl — of all languages, one that normally errs on the side of letting you leave out anything that can be inferred from context — Perl insists in its syntax documentation that in cases like this, “the curly brackets are required — no dangling statements allowed.” (It then says, in typically Perlish fashion: “If you want to write conditionals without curly brackets there are several other ways to do it.”)

If you’re working in one of those languages that lets you omit curly braces around a single-statement conditional — DON’T DO IT! The potential maintenance and debugging problems are not worth the fun of saving two keystrokes (or just one, if you work in an editor that auto-closes your braces for you).

A Single Context for All Social Interaction: Merely Quixotic, or Dangerously Misguided?

I recently read a blog post by Leo Widrich, the co-founder of Buffer, entitled “Why do we have so many lives?” In it, Mr. Widrich says:

We have a private life, a public life. We have a work life, a school life, a party life, a love life and I am sure you can name lots of others. I never understood why.… I always felt that it is hard enough to focus on getting one life right. Why create so many? (emphasis added)

This guy is a startup founder. I expect he may well be typical of the genus. And so, he makes a great example of why so many startups* seem to be promoting the “single identity” model. It’s nice that this guy feels he can have just one life — though even he admits it’s hard! But the rest of us don’t really want to deal with everyone on the same single channel.

Mr. Widrich claims that: “I can walk into a club and speak the same thoughts I have in my head to a girl, as I can to my family. And again I can speak with the same mindset to my co-founder, give an interview or play football.” Personally, I can’t help but wonder if that’s really working out for him. The pitch you use to woo an investor is quite seriously different from the kind you use to woo a woman. The way you talk to your girlfriend is very different from the way you talk to your mother or sister (I sincerely hope!).

In fact, I can’t help but wonder if this is a manifestation of Asperger’s Syndrome, or some other failure (or refusal) to understand social interaction. Regardless, it seems like a very clear example of a geek-specific sort of fallacy that — I’m starting to think — may underlie the various new systems that try to enforce single identities:

Figuring out the rules for social interaction is hard. One of the hardest parts is figuring out which rules apply in what contexts. Wouldn’t it be great to just have one context for everything?

No. No, it would not.

Most of us react with some consternation when our contexts collide unexpectedly — for example, meeting a co-worker (or boss!) at the supermarket (or worse, nightclub or bar!). Most of us don’t want our boss to see us drunk, or trying to pick people up. We don’t even really want to introduce our boss to our friends and have to try to integrate them into the conversation. Of course, being a startup founder, Mr. Widrich (like guys like Mark Zuckerberg and Larry Page) doesn’t have a boss, and so doesn’t have to worry about this.

The combination of “boss privilege” and “desire of poorly-socialized people to not have to deal with so many social contexts” makes a powerful one-two punch, and it may go a long way toward explaining the recent spate of apps that try to enforce single identities. In the meantime, I’m happily using Seesmic as my mobile phone’s Twitter client, because it has excellent support for multiple accounts.

* I include Google and Facebook in this category. They still think they’re startups, they still think like startups, and they still have the startup culture and mindset, even if they’ve grown into ginormous corporations. ^back

An Addendum: If you think the desire for multiple identities and contexts is just “an old people issue”, as LinkedIn CEO Reid Hoffman recently described “privacy” in Davos, then ask any teenager: Would you like to hang out with your parents, in the same way you hang out with your friends? How about your teachers?

If you have any doubt what their reaction would be, you don’t know teenagers very well.

By the way, a word to Mr. Hoffman: Apparently the new common wisdom is that LinkedIn is also “for old people”, so you might want to rethink your company’s stance on privacy. And quit pissing off your own target market.

A Failed Goal

Near the beginning of this year, I published a piece called “Ada Lovelace Day Is Not Enough“. In it, I noted that only 8.69% of my 2010 posts had been marked with the “gender” tag, and it would be nice to increase that percentage. (But it was still an improvement over 2009′s 4.76%.) I said:

So I may be improving… but I’ve still got a way to go. If you’re another man in tech reading this, I tell you what: I’ll work on improving myself, and the tech field as a whole, if you’ll do the same.

It’s now the end of 2011. Looking back over my blog activity this year, I see 24 posts, with only two tagged “gender”. That marks a slight drop to 8.33%. What happened?

I’ve had one in the works for months now. (Maybe more than one; there’s more than enough material.) I started it back in the summer, when I heard about the death threats against Naomi Dunford. In quick succession, before I could marshal my thoughts and words enough, there was the incident where the atheist/skeptic community blew up over SkepChick’s very polite advice on not acting like a scary creep (including Richard Dawkins blatantly showing his ass in a way that also showed off his monumental privilege and the ignorance it’s brought him), followed by the call for a stop to misogynist trolling and the associated #MenCallMeThings hashtag on Twitter. (Yes, it’s still going, and yes, it’s still worth reading if you want to see what women put up with online.) Read More »

Are We Always New At Everything?

The trend in Microsoft’s products for the past 15 years or more has been toward making things easy for the people who have never used the software before. Of course, as time goes on, there are fewer and fewer of those people.

The Ribbon is introduced in the Help file thus:

And if you’ve used previous versions of Word, you’ll wonder where the menus and toolbars have gone. That’s the beauty of the Ribbon. No longer do you have to wander through the maze of menus, submenus, and toolbars searching for what you want.

No, instead we now have to wander through a bewildering array of Ribbon tabs and drop-down menus. It’s as if the Office 2007 design team didn’t realize that everyone who’s been using Word for more than a year or two already knows their way around Word’s menu structure. It’s as if someone re-arranged my local neighborhood so that I “no longer have to wander through” the streets I already know. Indeed, SecretGeek finds the Ribbon so hard to find things in, he suggests that the Ribbon should include its own search feature so people can find features that are hidden among all those tabs!

It’s not just Microsoft. Check out Qwiki, “the information experience”. It is very clearly optimized to look cool in a demo. A demo, of course, is the ultimate in “aimed at new users” — it’s aimed at people who aren’t even users yet, but might become users. And user interface guru Bruce Tognazzini has been decrying the OS X Dock for years, partly on the basis that “It makes for a great demo, but not a great product.”

Interestingly, while I was prepping this post for publication, I became aware of Paul Miller’s article, “The Condescending UI”. It excoriates many of the very same problems in Apple’s and Microsoft’s recent OSes, saying that “these new tricks are horrible and offensive. They’re not only condescending and overwrought, they’re actually counter-functional.”

It’s as if usability tests and design reviews are all conducted with people who have never used the software in question before… and those who already have some domain knowledge are left out in the cold, forced to discard their knowledge every few years.

Are we really always newbies at everything? Or do developers even believe that we are? Or, heck, do marketers and product managers actually believe that we’re all still newbies? Or that there’s some vast, untapped market of prospective new users out there, just waiting for an even more dumbed-down interface before they’ll buy their first computer?

Just in case anyone out there believes any of those things, please, let me be the one to disabuse you of the notion. Anyone who doesn’t already use a computer is not ever going to. The only exception here is people under about 10 years old, and they’re not scared of unfamiliar UIs — to them, every UI is new, and they’re eager to learn new things. Stop dumbing things down, and stop sacrificing your long-time users’ skills in the name of changing things just for the hell of it.

Can You Strike it Rich in a Startup?

Startups are known for being places where people work really hard, often at unsustainable paces. “Work hard, play hard,” is the oft-invoked slogan, and there are usually foosball tables, game consoles, and other signifiers of fun lying around the office. (How often they get used is another story; the reality can easily be more like “work hard, then crash” or “work, eat, sleep”.) But there’s a logic behind it:

The idea is that you work really hard for a few years, but then there’s a big payout when your company goes public. In those few years, you can make enough money to live in comfort for quite a while. Or so the story goes. Does it actually happen that way?

Let’s try a quick experiment: Think of all the people you know, or have known, who have worked at startups. If you’re like me, working as a web developer in the Bay Area, this means “think of all your past and present co-workers”, and maybe a fair number of your friends who have worked for startups… just not the same ones as you.

Okay, total that up. Got a general ballpark number, at least? Great.

Now, how many of those people have actually gotten the kind of “big payout” that lets them live in comfort? Even for just a few years? Read More »