Writing code without tests usually looks like this for me. Let me know if it sounds familiar.
The process gets a little longer when I get to working with the full stack and am looking at the browser.
Hey I’ve watched (some of) the Abelson and Sussman lectures and know that programming by wishful thinking is useful so sometimes I create functions/methods that use a not complete implementation. That looks like:
This should sound familiar to some if not many of you.
What if I told you there was a framework for automating many of those steps? Wouldn’t that be awesome?
Steps like:
It’s call rSpec people (optionally with Guard). You can create those basic objects and wishfully-thought-of functions with rSpec stubs and mocks. You can check if your code works the way you think it should with should. You can even have those steps happen automatically with guard.
I invite you to not write tests (that’s boring), automate your process. Machines should work and people should think. The fact that you have a suite of tests and documentation at the end of the day is a bonus not the point.
—R
[excuse the poor grammar in the title, it’s a song title.]
I was directly effected by the recent EC2 outage as a Heroku customer. I’ve heard a lot of chatter about how this proves that the cloud isn’t “all that”. I disagree. Simply put downtime happens. One of the things that I pay for as a hosted (cloud) customer is that when downtime happens, I’m not stressed out trying to find the problem. Some very smart engineers are already working on the problem.
Yes, you should have redundant systems in place. It’s like backups, or making sure you don’t enter the crosswalk when the red hand is flashing. We all know that we should do it but we get burned so infrequently that it doesn’t often occur to us as important until we get singed. I’ll be looking for another cloud to host a backup in but I’m not going to be running scared to a colo or putting a server in my basement.
Furthermore, I’m going to keep offloading the things that I’m not good at (because I don’t choose to make it my focus) to providers that are good at them, in the cloud. Simple Worker is my next target. I looked at setting up a delayed job queue and immediately knew the direction I would be going when I saw that Simple Worker had made it their focus. I’m going to trust the person with focus to do it better than the dabbler even if the dabbler is me.
When I am working on a problem, I never think about beauty but when I have finished, if the solution is not beautiful, I know it is wrong.
R. Buckminster Fuller
I want to write more on this subject but for now I’m putting this out in the universe to remind me.
Philip Greenspun has a post that has caused a bit of an uproar in the Rails community. You have to scroll down quite a way to get to the moral of the story. Actually you have to scroll all the way down to the comments.
The point of the story was to show that the MIT-trained programmer with 20 years experience and an enthusiasm for the latest and greatest ended up building something that underperformed something put together by people without official CS training who apparently invested zero time in exploring optimal tools. Could some team of Rails experts have done a better job with mitgenius.com? Obviously they could have! But in the 2+ years that our MIT graduate worked on this site, he apparently did not converge on an acceptable solution.
and
I like this story because (1) it shows the fallacy of credentialism; a undergrad degree in CS is proof of nothing except that someone sat in a chair for four years…
From a business perspective; in a day and age where most of MIT’s CS catalog is available online for free in addition to a vast supply of other sources, why would you employ someone who payed $40k+ for a chunk of sheepskin with a fancy script font to build your next killer app or architect your environment? Likewise to the programmers of the world; why would you choose to work for someone so rigid and unimaginitive they’ve never questioned the “BS in CS or related” heuristic? One has to question whether such a hiring manager is interested in results or appearances.
Relational databases are meh. There are sexier storage technologies out there for web development like document oriented and object databases. Still the relational database is often the day to day workhorse of most of our projects.
Just a moment ago I had to decide what (relational) database to use to back a project I’m working on. I’m going with PostgreSQL. There are a lot of good reasons to use Postgres for this particular project; It’s already installed and configured, it has good features and standards compliance, and it’s free.
I’m wondering how other people and organizations choose their databases. It seems to me that Oracle and MySQL are often chosen by default. I’m not sure that is a reasonable default or merely name recognition.
More importantly to me recently is; should I be working with those ‘default’ databases in order to keep my skills current for potential employers or should I be using PostgreSQL? I’m thinking I’ll keep my PostgreSQL and possibly even work more with those sexier storage technologies mentioned above. I want to work with the cool kids so I should do what I perceive the cool kids to be doing.
Maybe I’m just a fanboy….
—R
That my friends and neighbors is the question. I could implement what I’m working on presently using either related tables and maybe some single table inheritance. Alternatively I could implement it using ActiveRecord’s composed_of functionality. So far I’ve done the latter. I was looking at prototyping the former.
After some consideration I’ve come to the conclusion that the data that I’m working with is not well formed. I’ve been told that the relational model is only good for highly structured data. I’m tending to believe that.
I’ve looked at document oriented databases. Now I need to prototype this application using one and figure out how I’m going to work the politics to get it to production should it work.
Still I’m curious… What *is* the relational model good for? It seems that we (the development community) use it for everything.
—R
I give you Mediocre In Place Controls
Basicly I needed to work around the use of the calendar helper in Super Inplace Controls.
—R
If like me you’ve been frustrated trying to get Dr. Nic’s Magic Models and ActiveScaffold working together Here’s your ghetto patch
—R