You are here

Code-Sprint Afternoon

I spent most of the day feeling like I was in a kind of frenzy working on four or five things at once: email, phone calls, walk-ins. The afternoon culminated with a mad code-sprint on two separate projects.

The morning was just a preview: I'm working with a student to set up a complex d7 site that will manage student applications to projects that faculty advertise. Trying to learn the changes associated with d7 while teaching the student has been challenging. We couldn't get the view block to show up on the front page. Eventually, I discovered that by default the block had been created to only show up on node-pages. Once I unchecked that, it worked fine -- but that cost me 45 minutes of fruitless struggling until I started googling around and figured out what was going on. I had a similar struggle to figure out why the exposed filters wouldn't show up -- it turns out you have to turn on Ajax. Who knew?

In the afternoon, I worked with Tom to set up yin/yang staging for the new microbiology drupal multisite. Our current plan is to build a multisite that can support d5, d6, d7, and d8 sites concurrently. Microbiology is transitioning to a new URL that allows us to set up the site and then migrate the old content into it. The bigger trick will be to impose the same structure on the Biology department website that is much larger, more complex, and already in full production.

Shortly after I started with Tom, I needed to also help Rodger who is learning to script running automated analyses using the BCRC computers. They have a data set with ~1600 individuals and ~9 loci and are measuring population structure fit making different assumptions about the number of populations. We crafted a first pass at the script a couple of days ago: I debated a bit about whether to write in the script in bash or perl, but eventually settled on PHP. People have been hating on PHP lately. (Well, that's really nothing new -- people have been hating on PHP since the very beginning). Still, I've been using PHP very nearly since the beginning (back in the PHP/FI days) and find it comfortable. The script is actually just a few control structures wrapped around shell commands. We parse the data file to measure the number of individuals and loci (using wc), we use a horrible string of piped sed commands to rewrite the mainparams file for the structure program, and then invoke the program with an algorithmically defined output filename, so the results won't get overwritten after each run.

I kept switching back and forth between each project, trying to keep Tom and Rodger engaged and just solving problems as necessary. It was a wonderful experience of flow: being totally absorbed in my work. At the end of the day, I was exhausted but sated at the same time. On days like this, I really love my job.