Thursday, March 29, 2007

road trip

All of our belongings are now in a 17' U Haul, and we will be hitting the proverbial road shortly, to head for sunny California. Goodbye, Seattle. We'll miss you.

Wednesday, March 21, 2007

functional tests

The first time I played with rails (two years ago), I was super sloppy about writing unit tests for my models - I wasn't working on a very complex product.

This time, I've been very diligent about writing unit tests - and it has definitely paid off.

Since my application structure is still in flux, though, I haven't written a single functional test. SO far, so good. But now it's getting to the point where things are just starting to blow up a little at a time. Which goes to show that any shortcuts you take in life will come bite you in the ass sooner or later.

So now I need to temporarily stop working on refining the product and go back and get myself up to speed on how to write functional tests, and start writing tests for all of the stuff I've done so far. Once I get over the initial inertia, adding new tests, and refactoring them as the application changes should be actually quite easy.

Better now than after I have customers, I suppose :)

Thursday, March 15, 2007

Good old music

A few years ago when I got my iPod, I decided not to import all of the random mp3s that I had from college - mainly because they came from various sources and didn't have all the ID3 tags in a consistent format.

So I started by importing the CDs that I owned, and slowly grew my collection.

Eventually, I moved all those mp3s off onto a backup drive and forgot about them.

Then, the other night, I remember that I had a live recording of a U2 song - and I hadn't heard it in ages. So I found that stash of mp3s and started importing a lot of that music into iTunes; fixing up the ID3 tags as I went.

And now I have all this great music from when I was in college and high school and it's bringing back wonderful memories. What a gift.

Monday, March 12, 2007

startup lesson 1 of 496,324

Keeping quiet about my business idea has been very difficult for me. Anyone who knows me knows that you can't get me to shut up on something I'm excited about. But I've been trying hard to be pretty hush hush about what I'm working on.

Why?

For one I've found that, for some inexplicable reason, whenever I talk about something, my effectiveness at actually executing on it dwindles. I dunno why, but it's as if the energy expended in talking about it takes away from the energy required to do it.

Second, I really want to get a first customer on board so that I can hone in on the idea and also develop some comfort that I'm barking up the right tree.

Well this morning I had breakfast with a friend, who's also starting a company. He's a little further along than me, though, and has funding and a formal company structure. After some conversation where I was being my usual evasive self when talking about the idea, he offerd to sign a mutual NDA so we could talk more freely. That threw me off - it's the first time someone has offered that. So I accepted and we spent the hour talking about our respective ideas and challenges and stuff.

After leaving, though, I felt like a bit of a dumbass. Why? Because the reason I wasn't talking about the idea wasn't/isn't lack of trust. It was for the reasons above. And yet, by agreeing to talk after signing an NDA, I basically affirmed that I don't trust him enough to tell him about my idea without signing some stupid piece of paper.

Obviously I don't regret the conversation itself - I learnt a lot from it. And hopefully you (I'm assuming he'll read this at some point) didn't walk away thinking that I don't trust you unless I have a signed piece of paper saying so. I think I just have to be a little more aware in the future.

Maybe I'm being naiive, but I think friendships are much stronger than any signed document.

What are your thoughts?

Specifically: 1) would you sign an NDA with friends? 2) are NDA's even effective at all when talking to peopled you don't know that well?

(NDA = Non Disclosure Agreement)

Friday, March 09, 2007

table conformity in rails

I want all my tables to have certain characteristics. E.g. I want them all to be UTF-8, and all have a field called 'created_at'.

Instead of duplicating that code everywhere, here's what I'm doing:


class MyTables < ActiveRecord::Migration
  def self.create_table( table_name, options={}, &table_definition )
options[:options] = "" unless( options.has_key?( :options ) )
options[:options] += " DEFAULT CHARSET=UTF8 "
super( table_name, options ) do |t|
t.column :created_at, :timestamp, :null => false
table_definition.call(t)
end
end
end

class Foo < MyTables
# use this like a regular migration
end



So now every migration Foo that inherits from MyTables automatically gets some default goodness.

Thursday, March 08, 2007

browser plugin idea...

There are a lot of books that people recommend to me that sound awesome but I don't quite want to own or read right away.

Imagine if you could select an ISBN number, or just visit the amazon.com page for a book, and click on a button in your browser. The plugin would automatically add it to your list of holds at the Seattle Public Library. You'd have to store your library number and PIN, and preferred pickup location with the plugin.

But after that, SPL will just send a notification when the book is available. Takes the hassle out of borrowing.

Also cool would be a wishlist importer that takes books (and maybe even cds and dvds) off your amazon wishlists and adds them to your list of library holds...

If such a thing exists, or if you write one as a result of this post, please let me know as I'd like to use it :)

insight

I recently attended a 10 day meditation retreat in Onalaska.

The course teaches Vipassana (loose English translation: 'insight'), and comes with quite a rigorous code of discipline (including no talking/reading/writing) for the duration of the course - which makes it a bit of a daunting endeavor to undertake. Nevertheless, at the recommendation of a few friends, I decided to go for it.

In line with what I had heard from friends, it was probably one of the most difficult things I've done in my life. Also in line with what others experienced, neither the 'noble silence' (see code of discipline) nor the limited meals and early wake up time (scroll to the bottom of the page) were as difficult as I thought.

While I was preparing myself for days of peaceful introspection followed by tumultuous emotions, this was quite the opposite. It ended up being a harrowing mental and physical experience (lots of thoughts, and pain respectively) that made it exceptionally difficult for the first few days.

The course was really an introduction to a theory of consciousness as espoused by Gautama Buddha, along with a technique that allows you to validate portions of that theory for yourself through direct experience. Obviously one cannot hope to completely understand consciousness within 10 days - no matter how rigorous the experience - but I feel as though the things I experienced first-hand allowed me to validate enough small pieces of the theory that I'm willing to not disbelieve the rest and trust that continued meditation will allow me to validate it for myself.

It's a little hard to attempt to lay the theory out here. But from mentioning it to a few people, it seems that it has enough in common with modern neuroscience, that it doesn't sound completely implausible. Specifically, I was recommended the book On Intelligence and told that some of the theories laid out there are very in line with the parts of the theory that I learnt.

In addition to that, I had a really cool conversation with someone who knows a lot about bipolar and the framework provided some interesting and different (no comments yet on whether they are useful) insights on what bipolar may mean.

Anyways, I know 10 days is a long time to take out of one's schedule, especially to sit quietly in one spot all day. But I think it was a fantastic experience. If you are a neuroscientist especially, I think you'd absolutely love going through this experience.

On a very very different note, A thought occurred to me today which I had to share. There are people that say that you make your own destiny and yet there are those that claim to be able to predict your future. I think I have an analogy that helps reconcile these into something that makes sense to me.

I've read many times that time is like a river. Always flowing, but always 'there'. In a whitewater course, one learns the very very basics of reading a river. Diagrams like these (scroll down) help tell you how bends, rocks, and changes in width of a river can affect its flow. Presumably if you know enough about the topology of a river, you can make a pretty educated guess about the strength and qualities of the currents at various points along it. And yet, nothing is preventing a big rock from rolling down the cliff and into the river and completely changing its flow. Or from erosion increasing the width and thus decreasing the strength of the current in a given place.

So if time, and life, are really like a river; then maybe there are people able to see the entire river at once and make fairly accurate predictions about downstream currents, given its current topology. But nothing prevents you from throwing a big old rock at the point of the river that we call 'now', and completely changing the downstream currents.

On that note, back to coding and attempting to start a successful business...

Tuesday, March 06, 2007

breakfast instead

I recently set up several breakfast appointments with friends instead of dinner. I really like the idea and think I'm going to do more of this if possible:
  • People generally have stuff planned in the evenings but not early in the morning
  • it's much healthier to eat a big breakfast instead of a big dinner (and I usually overeat when I eat out)
  • breakfast places are usually packed on the weekends (esp the good ones) - I'm guessing (hoping?) they're not as bad on the weekdays


So let's get together for breakfast sometime. There are a bunch of places that I haven't been to in a while, and a bunch that I haven't ever tried.