At Envisage, we have a 1 week iteration. This means that we typically don’t want a single story to go longer than one week. We also change up the pair rotation once per week. The estimation process is not perfect, though, and we have a lot of support from management to choose doing things right, rather than doing things now, which leads to stories going beyond a single iteration. So when this happens, there is usually a small rock/paper/scissors session with the developers involved to determine who will be taking the story. More often then not, the story goes with the machine (and the developer) that was used to do the work, since it is usually not practical to check in changes at the end of the week (also, our QA builds on Fri for a demo, so a green build is needed on Fri).
One approach to this, which occurred to myself, and one of our other developers at close to the same time, was to utilize the concept of a personal branch. This is something that I believe is supported transparently in TFS, though I’m not 100% sure. We are using Subversion, so the process is somewhat manual, but overall pretty easy to get started. Once a branch was created, I found it extremely liberating. I have apparently been making decisions about how much to change while I’m refactoring code at least partly based on how much work it will be to integrate directly back into the trunk. Having a private, protected area for me to work made it much easier to change things in the way they needed to be changed. It also meant that I could check in more often, including checking in changes which would leave the app in a non-functional state. Having those commit points meant that I could more easily undo changes, and gave me a nice warm and fuzzy feeling about the changes I was making. There was also another interesting advantage, and that was when another developer was asking me about how the API would look on some of the objects I was working on, and I was able to point him directly to my branch to see the changes.
There were a few issues, however. The biggest was that, though we are running the Subversion 1.5 server, our repository has not been updated, so the automatic merge tracking was not working. This meant that I had to keep track of the revision numbers myself whenever I needed to merge updates to the trunk into my branch. And this also made the “Reintegrate Branch” merge function impossible when I was ready to check my changes in. Despite these issues, I think in this particular case (the story lasted about 3 weeks) I was worth the extra effort, and made the overall process much easier. We will be updating our repository this week, which may make having a personal branch a viable solution for normal day-to-day work, but as it is the effort involved was a bit more than what I would want to deal with on a regular basis. I will certainly not hesitate to break out this tool whenever I’ve got either a long running, or a large scope (meaning either large numbers of files effected, or a large change to parts of the API) story. I certainly recommend giving it a try.