Program: 80713
Project: 80713
Buggy source:
@Override public boolean process(Set<? extends TypeElement> annotations,RoundEnvironment roundEnv){
  if (!roundEnv.processingOver()) {
    Collection<CodeGenerator> codeGenerators=getCodeGenerators();
    if (!roundEnv.errorRaised()) {
      CodeGen codegen=new CodeGen(processingEnv,roundEnv);
      codegen.getModels().forEach(entry -> {
        try {
          Model model=entry.getValue();
          if (outputDirectory != null) {
            Map<String,Object> vars=new HashMap<>();
            vars.put("String_Node_Str",new Helper());
            vars.put("String_Node_Str",processingEnv.getOptions());
            vars.put("String_Node_Str",File.separator);
            vars.put("String_Node_Str",model.getFqn());
            vars.put("String_Node_Str",model.getModule());
            vars.put("String_Node_Str",model);
            vars.putAll(model.getVars());
            for (            CodeGenerator codeGenerator : codeGenerators) {
              if (codeGenerator.kind.equals(model.getKind())) {
                String relativeName=(String)MVEL.executeExpression(codeGenerator.filenameExpr,vars);
                if (relativeName != null) {
                  if (relativeName.endsWith("String_Node_Str") && !relativeName.contains("String_Node_Str")) {
                    String fqn=relativeName.substring(0,relativeName.length() - "String_Node_Str".length());
                    if (processingEnv.getElementUtils().getTypeElement(fqn) != null) {
                      return;
                    }
                    JavaFileObject target=processingEnv.getFiler().createSourceFile(fqn);
                    String output=codeGenerator.transformTemplate.render(model);
                    try (Writer writer=target.openWriter()){
                      writer.append(output);
                    }
                   }
 else {
                    File target=new File(outputDirectory,relativeName).getAbsoluteFile();
                    if (codeGenerator.incremental) {
                      List<ModelProcessing> processings=generatedFiles.computeIfAbsent(target,GeneratedFile::new);
                      processings.add(new ModelProcessing(model,codeGenerator));
                    }
 else {
                      codeGenerator.transformTemplate.apply(model,target);
                    }
                  }
                  log.info("String_Node_Str" + model.getFqn() + "String_Node_Str"+ relativeName);
                }
              }
            }
          }
 else {
            log.info("String_Node_Str" + model.getFqn());
          }
        }
 catch (        GenException e) {
          reportGenException(e);
        }
catch (        Exception e) {
          reportException(e,entry.getKey());
        }
      }
);
    }
  }
 else {
    generatedFiles.values().forEach(generated -> {
      try (FileWriter fileWriter=new FileWriter(generated.file)){
        for (int i=0; i < generated.size(); i++) {
          ModelProcessing processing=generated.get(i);
          Map<String,Object> vars=new HashMap<>();
          vars.put("String_Node_Str",i);
          vars.put("String_Node_Str",generated.size());
          vars.put("String_Node_Str",generated.session);
          try {
            String part=processing.generator.transformTemplate.render(processing.model,vars);
            fileWriter.append(part);
          }
 catch (          GenException e) {
            reportGenException(e);
          }
catch (          Exception e) {
            reportException(e,processing.model.getElement());
          }
        }
      }
 catch (      Exception e) {
        reportException(e,generated.get(0).model.getElement());
      }
    }
);
  }
  return true;
}

Fixed version (ground truth):
@Override public boolean process(Set<? extends TypeElement> annotations,RoundEnvironment roundEnv){
  if (!roundEnv.processingOver()) {
    Collection<CodeGenerator> codeGenerators=getCodeGenerators();
    if (!roundEnv.errorRaised()) {
      CodeGen codegen=new CodeGen(processingEnv,roundEnv);
      codegen.getModels().forEach(entry -> {
        try {
          Model model=entry.getValue();
          if (outputDirectory != null) {
            Map<String,Object> vars=new HashMap<>();
            vars.put("String_Node_Str",new Helper());
            vars.put("String_Node_Str",processingEnv.getOptions());
            vars.put("String_Node_Str",File.separator);
            vars.put("String_Node_Str",model.getFqn());
            vars.put("String_Node_Str",model.getModule());
            vars.put("String_Node_Str",model);
            vars.putAll(model.getVars());
            for (            CodeGenerator codeGenerator : codeGenerators) {
              if (codeGenerator.kind.equals(model.getKind())) {
                String relativeName=(String)MVEL.executeExpression(codeGenerator.filenameExpr,vars);
                if (relativeName != null) {
                  if (relativeName.endsWith("String_Node_Str") && !relativeName.contains("String_Node_Str")) {
                    String fqn=relativeName.substring(0,relativeName.length() - "String_Node_Str".length());
                    if (processingEnv.getElementUtils().getTypeElement(fqn) != null) {
                      return;
                    }
                    JavaFileObject target=processingEnv.getFiler().createSourceFile(fqn);
                    String output=codeGenerator.transformTemplate.render(model);
                    try (Writer writer=target.openWriter()){
                      writer.append(output);
                    }
                   }
 else {
                    File target=new File(outputDirectory,relativeName).getAbsoluteFile();
                    if (codeGenerator.incremental) {
                      List<ModelProcessing> processings=generatedFiles.computeIfAbsent(target,GeneratedFile::new);
                      processings.add(new ModelProcessing(model,codeGenerator));
                    }
 else {
                      codeGenerator.transformTemplate.apply(model,target);
                    }
                  }
                  log.info("String_Node_Str" + model.getFqn() + "String_Node_Str"+ relativeName);
                }
              }
            }
          }
 else {
            log.info("String_Node_Str" + model.getFqn());
          }
        }
 catch (        GenException e) {
          reportGenException(e);
        }
catch (        Exception e) {
          reportException(e,entry.getKey());
        }
      }
);
    }
  }
 else {
    generatedFiles.values().forEach(generated -> {
      File file=generated.file;
      Helper.ensureParentDir(file);
      try (FileWriter fileWriter=new FileWriter(file)){
        for (int i=0; i < generated.size(); i++) {
          ModelProcessing processing=generated.get(i);
          Map<String,Object> vars=new HashMap<>();
          vars.put("String_Node_Str",i);
          vars.put("String_Node_Str",generated.size());
          vars.put("String_Node_Str",generated.session);
          try {
            String part=processing.generator.transformTemplate.render(processing.model,vars);
            fileWriter.append(part);
          }
 catch (          GenException e) {
            reportGenException(e);
          }
catch (          Exception e) {
            reportException(e,processing.model.getElement());
          }
        }
      }
 catch (      Exception e) {
        reportException(e,generated.get(0).model.getElement());
      }
    }
);
  }
  return true;
}