November 25, 2016

Enum vs. Active Record any?

Today at work I saw a really weird exception in prod. The code is in a Rails project using ActiveRecord and was something like this: And the dreaded exception that makes every rubyist want to cry: If there are any? of my things how can the first one be nil? When I saw this I had to remind myself of the best debugging advice I ever got: There has to be a reason. Computers are just machines, they just follow instructions. If the code after if was executed, the condition before it had to be true. […2 min read]

post#databases#rails#ruby#web-development

September 5, 2016

What your rails app does behind the scenes

Ever wondered what your rails app is really doing? When I first started learning Rails it seemed like magic. I finally got started building some rails apps and couldn't believe I could get one up and running in 5 minutes. What is this magic? Needless to say there's a lot going on behind the scenes. I was living in blissful ignorance, building away and not worrying about how it all worked until it didn't anymore. […6 min read]

post#mvc#rails#web-development