Spot any errors? let me know, but Unleash your pedant politely please.

Friday, 23 March 2012

openpyxml win

I'm a software tester. I write and run a lot of test scripts. These scripts are usually written in Excel.

Excel feels much more appropriate than a dedicated test case management environment. It is a tester's tool, not a management tool. Its Achilles heel, however, is the fragility of inter-workbook linking. It just doesn't seem possible to create and maintain relative links for multiple users.

Using a separate summary/reporting workbook to show test progress requires quite a lot of link plumbing. This plumbing is a maintenance nightmare.

My current project is in its infancy. The shit and the fan aren't even in the same room yet. I have time to put things in place. Time to do something about the plumbing. I can't fix Excel, but I can rip out most of the troublesome plumbing.

I've had some success with Apache POI in the past (Java library for reading/writing Excel files). My Eclipse and Java skills are rusty, but my Python is not.

A little Googling gave me a few options. The first I tried was openpyxl. It worked, so I saw no reason to look beyond it.

The Test Scripts are all based on a template devised and maintained by the testers. This template has some rows at the top containing a live view of the state of the sheet (number of steps, number of passes, number of failures).

I've now reduced the plumbing to a few cells in a workbook that link to a few cells in a CSV. This CSV is written by a Python script that scans a folder and its subfolder for Excel files and uses openpyxl to scrape values from the results cells of test scripts.

If new scripts are created somewhere in the folder structure, these will show up in the CSV.

It's also possible to generate a summary at each level of folder hierarchy. That means we can create a meaningful hierarchy - say reflecting the requirements hierarchy - and easily get a summary at level.

Another benefit is that we can split long test scripts into smaller individual test cases. The Python that scrapes the results will simply find them all without any additional work.

Thursday, 2 February 2012

Single Story, Television and Violet Blue

Last night, due to very bad WiFi in my hotel, I watched a few TED videos I'd downloaded in case the WiFi in my hotel room was very bad. One was just superb. It was 'The Danger of a Single Story' from Chimamanda Adichie. I'd never heard of her before, but just ordered a couple of her books on the strength of how much I enjoyed this:











It made me think of The Wire. Just as Chimamanda was stuck telling single stories in her early writing, the majority of TV is stuck telling single stories. The majority of characters in TV are superficial. One dimensional. They have a single story … good policeman … bent copper… drug dealer … guy in red shirt in away team to the planet surface.

Characters become multi-dimensional when we know more than one of their stories. I've always thought this is why The Wire is so good. Most the characters have more than one story. It's not possible to do this for all of them, of course. Some minor characters are never fleshed out. Some characters have to wait for several seasons to pass before getting more of their stories told. After this happened a couple of times, I stopped judging characters on their single-story - being patient for the reveal of a second, third … nth story.

I haven't always extended that patience in the real world, but it's something I shall endeavour to do, having thought about it in this way.


I'm going to have to consider whether this is also why I like The Killing and Borgen. I think it's why Skins and Misfits are so good - they present single-story stereotypes intially, but dedicate whole episodes to fleshing out each of the main characters by giving them additional stories.

This assumption of a single story is what's bitten Violet Blue in captioning "The Saddest Booth Babe In The World" ). I'm not going to judge her too harshly. She'd just responding to a single story in he way most of us often do. She's not doing herself any favours, however, by not reconsidering, not apologising, not learning, not growing.

A person at conference booth can be a young attractive women, with breasts in a tight t-shirt, representing herself and her work and her nerdery. A young attractive woman, with breasts in a tight t-shirt is not necessarily hired marketing eye-candy. She may be bored and tired and disillusioned. She may be struggling to overcome shyness or social awkwardness (I am imagining myself in a similar situation). She may be sitting there thinking "Fuck! I wish I'd hired a booth-babe. I suck at this!"

Tuesday, 13 December 2011

Rivers of London (Peter Grant, #1)Rivers of London by Ben Aaronovitch

My rating: 3 of 5 stars


Picked this up at the airport last week. It's an odd mix. Like a Mark Billingham rewritten by Robert Rankin. It also reminds me of Neil Gaiman's Neverwhere.

The main sticking point is that there's a lack of balance between historical background and complexity of plot. It feels like 100 pages of plot and 250 pages of historical/geographical filler.

It's closer to Rankin or Pratchett than Gaiman. So if you like that kind of thing, you'll probably like this.



View all my reviews

Tuesday, 13 September 2011

Trying out ifttt


Really interesting and nicely designed new service called ifttt. It lets you link web stuff. I'm giving it a whirl right here by linking my blog, such as it is, to Twitter. I partly chose this because I don't update the blog often, and so it shouldn't annoy people too much. I'd also probably tweet about most blog posts anyway.

I haven't read T&Cs yet. I'm mostly positive about this, but I can see how it could potentially be abused.

Sunday, 15 May 2011

Cube Destroyed

We acquired a new bed to replace the one in my son's room, which was a temporary stop-gap gratefully received from Freecycle. I have instructions to put the new one in my daughter's room, and move the one in my daughter's room into my son's room. I'm not quite sure why. I just do as I'm told.

I got a bit pissed off because there were a number of my small geek screwdrivers on the floor, no in their box, and a couple of them were broken. There was also a greasy plate under the bed.

That was nothing though, compared to what I found when I lifted the mattress. No, not a jazz mag, they have teh internetz for that these days, what I found was my Apple Cube, which should've been in its box in my bedroom, ready for eBayinig, or put to some other use.

It was old and had a couple of faults: USB and modem on the motherboard were broken. Ethernet was OK though, and USB via ADC worked. So it was a functioning, but old.

What I found was basically everything stripped to the smallest possible component. This is what's left of it:

Saturday, 14 May 2011

nightCoder

I'm currently working in Switzerland, commuting weekly, flying out on Monday morning and back on Friday afternoon. Last weekend, my colleague Charles and I elected to stay for the weekend. It meant an additional day of work by not losing Friday afternoon and Monday morning travelling.
We took Saturday off to explore Milan a little, worked on Sunday morning at the client's office, and then had an afternoon on the terrace with cheese, ham, bread an beer for lunch. We had a problem sharing the ADSL, but I wanted to do a little more work on a test tool, so Charles surfed, and I worked.
We took a break to use the hotel pools for an hour or so. I had the chilly outdoor pool to myself. Charles had the heated indoor pool to himself. Then we drove into through Lugano, out around and back through Paradiso and back to the lake. We ate at a chain restaurant, The Spaghetti Store. It's not as nice as the restaurants in the surrounding villages, but it's right by the lake, and it was a warm clear night.
When we got back to the hotel, there were beers left if the fridge, so we repaired once more to the terrace. We tried open unencrypted sharing of the ADSL via WiFi, which worked. Charles surfed and I surfed a little but mostly continued to work on the test tool. I had neglected to plug in my power supply, but finished what I wanted to to do with 10% battery left. Charles was still surfing, but was reliant on my Wifi. I decided not to plug into the power, it was an opportunity to run the battery completely flat. I caught up with a few RSS feeds and gave Charles a countdown on the power situation. I think it finally died at 1:30am.

So here I am, coding, at night, not in a cubicle (or equivalent). It was pretty sweet:




And yes. It was Python.

Wednesday, 9 March 2011

Offensive.

I've just been reading a Grauniad article: Not quite a paedophile' – John Humphrys' strange correction in which Tanya Gold has written:
Mainstream porn actresses – I will not call a woman who is a paid-for receptacle for semen a "star".
Yes. Really. In a written piece about poor choice of words on live radio, one woman calls another woman a spunk bucket.

I'd love to hear Anna Span or Belle de Jour's opinion on this.