Program: 16000
Project: 16000
Buggy source:
public void render(final Row row,final Object data,final int index){
  final Rows rows=(Rows)row.getParent();
  final Grid grid=(Grid)rows.getParent();
  final int size=grid.getModel().getSize();
  final String subtype=row instanceof Group ? "String_Node_Str" : row instanceof Groupfoot ? "String_Node_Str" : null;
  final Template tm=resolveTemplate(grid,row,data,index,size,"String_Node_Str",subtype);
  if (tm == null) {
    final Label label=newRenderLabel(Objects.toString(data));
    label.applyProperties();
    label.setParent(row);
    row.setValue(data);
  }
 else {
    final ForEachStatus iterStatus=new AbstractForEachStatus(){
      private static final long serialVersionUID=1L;
      public int getIndex(){
        return index;
      }
      public Object getEach(){
        return data;
      }
      public Integer getEnd(){
        return size;
      }
    }
;
    final String var=(String)tm.getParameters().get(EACH_ATTR);
    final String varnm=var == null ? EACH_VAR : var;
    final String itervar=(String)tm.getParameters().get(STATUS_ATTR);
    final String itervarnm=itervar == null ? (var == null ? EACH_STATUS_VAR : varnm + STATUS_POST_VAR) : itervar;
    Object oldVar=grid.getAttribute(varnm);
    Object oldIter=grid.getAttribute(itervarnm);
    grid.setAttribute(varnm,data);
    grid.setAttribute(itervarnm,iterStatus);
    final Component[] items=tm.create(rows,row,null,null);
    grid.setAttribute(varnm,oldVar);
    grid.setAttribute(itervarnm,oldIter);
    if (items.length != 1)     throw new UiException("String_Node_Str" + items.length);
    final Row nr=(Row)items[0];
    nr.setAttribute(BinderImpl.VAR,varnm);
    nr.setAttribute(AbstractRenderer.IS_TEMPLATE_MODEL_ENABLED_ATTR,true);
    nr.setAttribute(AbstractRenderer.CURRENT_INDEX_RESOLVER_ATTR,iterStatus);
    addItemReference(grid,nr,index,varnm);
    nr.setAttribute(itervarnm,iterStatus);
    if (nr instanceof Group && row instanceof Group) {
      ((Group)nr).setOpen(((Group)row).isOpen());
    }
    nr.setAttribute(TemplateResolver.TEMPLATE_OBJECT,row.removeAttribute(TemplateResolver.TEMPLATE_OBJECT));
    addTemplateTracking(grid,nr,data,index,size);
    if (nr.getValue() == null)     nr.setValue(data);
    row.setAttribute("String_Node_Str",nr);
    row.detach();
  }
}

Fixed version (ground truth):
public void render(final Row row,final Object data,final int index){
  final Rows rows=(Rows)row.getParent();
  final Grid grid=(Grid)rows.getParent();
  final int size=grid.getModel().getSize();
  final String subtype=row instanceof Group ? "String_Node_Str" : row instanceof Groupfoot ? "String_Node_Str" : null;
  final Template tm=resolveTemplate(grid,row,data,index,size,"String_Node_Str",subtype);
  if (tm == null) {
    final Label label=newRenderLabel(Objects.toString(data));
    label.applyProperties();
    label.setParent(row);
    row.setValue(data);
  }
 else {
    final ForEachStatus iterStatus=new AbstractForEachStatus(){
      private static final long serialVersionUID=1L;
      public int getIndex(){
        return index;
      }
      public Object getEach(){
        return data;
      }
      public Integer getEnd(){
        return size;
      }
    }
;
    final String var=(String)tm.getParameters().get(EACH_ATTR);
    final String varnm=var == null ? EACH_VAR : var;
    final String itervar=(String)tm.getParameters().get(STATUS_ATTR);
    final String itervarnm=itervar == null ? (var == null ? EACH_STATUS_VAR : varnm + STATUS_POST_VAR) : itervar;
    Object oldVar=grid.getAttribute(varnm);
    Object oldIter=grid.getAttribute(itervarnm);
    grid.setAttribute(varnm,data);
    grid.setAttribute(itervarnm,iterStatus);
    final Component[] items=tm.create(rows,row,null,null);
    grid.setAttribute(varnm,oldVar);
    grid.setAttribute(itervarnm,oldIter);
    if (items.length != 1)     throw new UiException("String_Node_Str" + items.length);
    final Row nr=(Row)items[0];
    nr.setAttribute(BinderImpl.VAR,varnm);
    addItemReference(grid,nr,index,varnm);
    nr.setAttribute(itervarnm,iterStatus);
    if (nr instanceof Group && row instanceof Group) {
      ((Group)nr).setOpen(((Group)row).isOpen());
    }
    nr.setAttribute(TemplateResolver.TEMPLATE_OBJECT,row.removeAttribute(TemplateResolver.TEMPLATE_OBJECT));
    addTemplateTracking(grid,nr,data,index,size);
    if (nr.getValue() == null)     nr.setValue(data);
    row.setAttribute("String_Node_Str",nr);
    row.detach();
  }
}