views:

490

answers:

6

I have been studying and reading about Scrum in the last few days and reading about Spring Planning and tasks, one problem that popped into my mind is how to deal with bugs in Scrum. Henrik Kniberg in his very nice book Scrum and XP from the Trenches lists some ways of dealing with this issue:

  1. Product owner prints out the most high priority Jira items, brings them to the sprint planning meeting, and puts them up on the wall together with the other stories (thereby implicitly specifying the priority of these items compared to the other stories).
  2. Product owner creates stories that refer to Jira items. For example “Fix the most critical back office reporting bugs, Jira-124, Jira- 126, and Jira-180”.
  3. 3) Bug-fixing is considered to be outside of the sprint, i.e. the team keeps a low enough focus factor (for example 50%) to ensure that they have time to fix bugs. It is then simply assumed that the team will spend a certain amount of time each sprint fixing Jira- reported bugs
  4. Put the product backlog in Jira (i.e. ditch Excel). Treat bugs just like any other story.

Is this really something that needs to be decided per-project basis or are there better solutions? I can think of problems with each of those approaches would a combination of all of those have a possibility of being a "one-for-all" solution? How do you handle this in your projects?

+2  A: 

There is no one size fits all solution and each project is different. Bugs might also be categorized from mission critical to hardly worth fixing.

Unless critical to the running of the system, I prefer bugs to become story cards. That makes the priority of feature development vs. bug fixing really explicit. In a scenario where bug fixes are considered to be "outside of the sprint" the bug fixing might move toward fixing really trivial bugs while really important business features aren't being developed.

We've gone trough a number of permutations before setting on the bug as a story approach. Try some different things and replay them at team retro meetings.

leonm
+1  A: 

In our case (greenfield development, 2-3 devs) found bugs are written down, marked clearly as a bug and based on their severity they are assigned to next iteration or left in the backlog. In case of critical and urgent bugs they are added to the ongoing iteration.

Petteri Hietavirta
+6  A: 

This is a very good question and I have some observations when it comes to different approaches to this problem.

  1. Treating all bugs equally with backlog items might sound like a good idea in theory (work tracked in a single place) but doesn't work well in practice. Bugs are usually low-level and more numerous, so if you create an individual user story for each bug then the "real" stories will get obscured soon.
  2. Explicit time in each sprint reserved for fixes is fine if done in a way that is visible for the product owner. Bugs should be mentioned during the daily scrum and discussion about bugs fixed should occur during the sprint review. Otherwise the product owner won't be aware of what's going on in the project.
  3. Putting the whole backlog in bug tracking tool leads to the same set of problems as in 1. Moreover most bug trackers are not designed with Scrum in mind and using them for this purpose can be painful.

The solution we found the most satisfying was to put a single user story called "Tickets" or "Bugs" on every sprint. Then such a story can be divided either into low-level tasks describing a particular bug (if known during planning) or meta-tasks reserving a given number of hours for general bug fixing. This way the product owner has visibility into the process and the burndown chart reflects the progress.

Just remember to mercilessly close all "bugs" that are actually new features and create new backlog items for them. Also make sure to fix all the bugs reported against the current sprint before the sprint is over in order to consider the sprint as done.

Adam Byrtek
My team follows a similar solution.
matt b
+1  A: 

Don't track defects on a list, find them and fix them -- Mary Poppendieck

Indeed, If inventory is waste, what about an inventory of defects...

That's why I always try to implement a Stop-the-Line mentality with test-driven development and continuous integration, so that we find and fix most defects instead of putting them on a rework list.

And when defects pass through, we fix them before writing new code (stories with bugs aren't done anyway). Then, we try to fix our process to make it more mistake-proof and detect defects the moment they occur.

Pascal Thivent
+2  A: 

Hey.
Actually I think that best is answer by jpeacock from this question http://stackoverflow.com/questions/175344/do-you-count-the-hours-spent-on-bug-fixes-towards-the-scrum

Let me cite it:

  • If the bug is easy/quick to fix (one liner, etc), then just fix it.
  • If the bug is not trivial, and not a blocker, then add it to the backlog.
  • If the bug is a blocker then add a task (to the current sprint) to capture the work required to fix it, and start working on it. This requires that something else be moved (from the current sprint) to the backlog to account for the new hours because your total hours available hasn't changed.
yoosiba
A: 

The first step is to define what a bug is. I teach that a bug is only a bug if it is functionality that does not work in production as it was intended/designed. These become bug type PBIs to be prioritized against new development. Missing functionality in production is a Feature and becomes a normal product backlog item. Any defective code found during a sprint is considered incomplete work and since you don't move on to the next story until the current one is done-done; it is unnecessary to track these defects in the sprint as the team is always working on the offending code. Post-its can be super handy here for quick reminders between team-mates. Fixing broken code always takes precedent over writing new code. If the defects are due to misunderstanding the story then you need to work on your conditions of acceptance before starting the story.

Inventory is waste. Bug tracking is inventory. Bug tracking is waste.

Treating all bugs equally with backlog items might sound like a good idea in theory (work tracked in a single place) but doesn't work well in practice. Bugs are usually low-level and more numerous, so if you create an individual user story for each bug then the "real" stories will get obscured soon.

If you have that many more bugs than features then you need to work on your engineering practices. This is a smell that something else is wrong and tracking is not the answer. Dig deeper. Actually bugs are always smelly. They aren't cool and if you have lots of them you need to find the root causes(s), eliminate those, and stop focusing on tracking bugs.

DancesWithBamboo