nus-yam/ex-repair huggingface dataset:
Program: 86438
Project: 86438
Buggy source:
@Override public void processQuery(@NotNull final ReferencesSearch.SearchParameters searchParameters,@NotNull final Processor<PsiReference> processor){
  ApplicationManager.getApplication().runReadAction(new Runnable(){
    @Override public void run(){
      Collection<ConceptStepImpl> conceptSteps=getConceptSteps(searchParameters.getElementToSearch(),searchParameters.getScopeDeterminedByUser().getDisplayName());
      Collection<SpecStep> specSteps=getSpecSteps(searchParameters.getElementToSearch(),searchParameters.getScopeDeterminedByUser().getDisplayName());
      Class<? extends PsiElement> elementClass=searchParameters.getElementToSearch().getClass();
      if (elementClass.equals(ConceptStepImpl.class))       handleConceptStep(conceptSteps,specSteps,searchParameters,processor);
 else       if (elementClass.equals(PsiAnnotationImpl.class) || elementClass.equals(PsiMethodImpl.class))       handleAnnotation(conceptSteps,specSteps,searchParameters,processor);
 else       if (elementClass.equals(SpecStepImpl.class))       handleSpecStep(conceptSteps,specSteps,searchParameters,processor);
    }
  }
);
}

Fixed version (ground truth):
@Override public void processQuery(@NotNull final ReferencesSearch.SearchParameters searchParameters,@NotNull final Processor<PsiReference> processor){
  if (searchParameters.getScopeDeterminedByUser().getDisplayName().equals("String_Node_Str"))   return;
  ApplicationManager.getApplication().runReadAction(new Runnable(){
    @Override public void run(){
      Collection<ConceptStepImpl> conceptSteps=getConceptSteps(searchParameters.getElementToSearch());
      Collection<SpecStep> specSteps=getSpecSteps(searchParameters.getElementToSearch());
      Class<? extends PsiElement> elementClass=searchParameters.getElementToSearch().getClass();
      if (elementClass.equals(ConceptStepImpl.class))       handleConceptStep(conceptSteps,specSteps,processor,(ConceptStepImpl)searchParameters.getElementToSearch());
 else       if (elementClass.equals(PsiAnnotationImpl.class) || elementClass.equals(PsiMethodImpl.class))       handleAnnotation(conceptSteps,specSteps,processor,searchParameters.getElementToSearch());
 else       if (elementClass.equals(SpecStepImpl.class))       handleSpecStep(conceptSteps,specSteps,processor,(SpecStepImpl)searchParameters.getElementToSearch());
    }
  }
);
}
Program: 86439
Project: 86439
Buggy source:
private void handleConceptStep(Collection<ConceptStepImpl> conceptSteps,Collection<SpecStep> specSteps,ReferencesSearch.SearchParameters searchParameters,Processor<PsiReference> processor){
  String conceptStepText=getConceptStepText((ConceptStepImpl)searchParameters.getElementToSearch());
  for (  ConceptStepImpl conceptStep : conceptSteps)   process(processor,conceptStep,replaceParamValues(conceptStepText).equals(replaceParamValues(getConceptStepText(conceptStep))));
  for (  final SpecStep specStep : specSteps)   process(processor,specStep,replaceParamValues(conceptStepText).equals(getStepAnnotationText(specStep)));
}

Fixed version (ground truth):
private void handleConceptStep(Collection<ConceptStepImpl> conceptSteps,Collection<SpecStep> specSteps,Processor<PsiReference> processor,ConceptStepImpl elementToSearch){
  String conceptStepText=getConceptStepText(elementToSearch);
  for (  ConceptStepImpl conceptStep : conceptSteps)   process(processor,conceptStep,replaceParamValues(conceptStepText).equals(replaceParamValues(getConceptStepText(conceptStep))));
  for (  final SpecStep specStep : specSteps)   process(processor,specStep,replaceParamValues(conceptStepText).equals(getStepAnnotationText(specStep)));
}
Program: 86440
Project: 86440
Buggy source:
private void handleSpecStep(Collection<ConceptStepImpl> conceptSteps,Collection<SpecStep> specSteps,ReferencesSearch.SearchParameters searchParameters,Processor<PsiReference> processor){
  String text=getStepAnnotationText(((SpecStepImpl)searchParameters.getElementToSearch()));
  for (  ConceptStepImpl conceptStep : conceptSteps)   process(processor,conceptStep,text.equals(getConceptStepText(conceptStep)));
  text=((SpecStepImpl)searchParameters.getElementToSearch()).getName();
  for (  final SpecStep specStep : specSteps)   process(processor,specStep,text != null && specStep.getName() != null && specStep.getName().trim().equals(text.trim()));
}

Fixed version (ground truth):
private void handleSpecStep(Collection<ConceptStepImpl> conceptSteps,Collection<SpecStep> specSteps,Processor<PsiReference> processor,SpecStepImpl elementToSearch){
  String text=getStepAnnotationText(elementToSearch);
  for (  ConceptStepImpl conceptStep : conceptSteps)   process(processor,conceptStep,text.equals(getConceptStepText(conceptStep)));
  text=elementToSearch.getName();
  for (  final SpecStep specStep : specSteps)   process(processor,specStep,text != null && specStep.getName() != null && specStep.getName().trim().equals(text.trim()));
}
Program: 86441
Project: 86441
Buggy source:
public void addCompletions(@NotNull CompletionParameters parameters,ProcessingContext context,@NotNull CompletionResultSet resultSet){
  resultSet=resultSet.withPrefixMatcher(new PlainPrefixMatcher("String_Node_Str"));
  SpecDetail specDetail=PsiTreeUtil.getChildOfType(parameters.getOriginalFile(),SpecDetail.class);
  SpecTable table=specDetail.getDataTable();
  if (table != null) {
    List<String> headers=table.getTableHeader().getHeaders();
    for (    String header : headers) {
      LookupElementBuilder item=LookupElementBuilder.create(header);
      resultSet.addElement(item);
    }
  }
}

Fixed version (ground truth):
public void addCompletions(@NotNull CompletionParameters parameters,ProcessingContext context,@NotNull CompletionResultSet resultSet){
  String prefix=getPrefix(parameters);
  resultSet=resultSet.withPrefixMatcher(new PlainPrefixMatcher(prefix));
  SpecDetail specDetail=PsiTreeUtil.getChildOfType(parameters.getOriginalFile(),SpecDetail.class);
  SpecTable table=specDetail.getDataTable();
  if (table != null) {
    List<String> headers=table.getTableHeader().getHeaders();
    for (    String header : headers) {
      LookupElementBuilder item=LookupElementBuilder.create(header);
      resultSet.addElement(item);
    }
  }
}
Program: 86442
Project: 86442
Buggy source:
@Override protected void addCompletions(@NotNull CompletionParameters parameters,ProcessingContext context,@NotNull CompletionResultSet resultSet){
  resultSet=resultSet.withPrefixMatcher(new PlainPrefixMatcher("String_Node_Str"));
  PsiFile specFile=parameters.getOriginalFile();
  SpecDetail specDetail=PsiTreeUtil.getChildOfType(specFile,SpecDetail.class);
  List<SpecStep> stepsInFile=new ArrayList<SpecStep>();
  addContextSteps(specDetail,stepsInFile);
  addStepsInScenarios(specFile,stepsInFile);
  Set<String> staticArgs=getArgsFromSteps(stepsInFile);
  for (  String arg : staticArgs) {
    if (arg != null) {
      LookupElementBuilder item=LookupElementBuilder.create(arg);
      resultSet.addElement(item);
    }
  }
}

Fixed version (ground truth):
@Override protected void addCompletions(@NotNull CompletionParameters parameters,ProcessingContext context,@NotNull CompletionResultSet resultSet){
  String prefix=getPrefix(parameters);
  resultSet=resultSet.withPrefixMatcher(new PlainPrefixMatcher(prefix));
  PsiFile specFile=parameters.getOriginalFile();
  SpecDetail specDetail=PsiTreeUtil.getChildOfType(specFile,SpecDetail.class);
  List<SpecStep> stepsInFile=new ArrayList<SpecStep>();
  addContextSteps(specDetail,stepsInFile);
  addStepsInScenarios(specFile,stepsInFile);
  Set<String> staticArgs=getArgsFromSteps(stepsInFile);
  for (  String arg : staticArgs) {
    if (arg != null) {
      LookupElementBuilder item=LookupElementBuilder.create(arg);
      resultSet.addElement(item);
    }
  }
}
Program: 86443
Project: 86443
Buggy source:
public void addCompletions(@NotNull CompletionParameters parameters,ProcessingContext context,@NotNull CompletionResultSet resultSet){
  resultSet.stopHere();
  String prefix=parameters.getPosition().getText().replace("String_Node_Str","String_Node_Str").trim();
  resultSet=resultSet.withPrefixMatcher(new PlainPrefixMatcher(prefix));
  Module moduleForPsiElement=ModuleUtil.findModuleForPsiElement(parameters.getPosition());
  if (moduleForPsiElement == null) {
    return;
  }
  for (  String step : getStepsInModule(moduleForPsiElement)) {
    LookupElementBuilder element=LookupElementBuilder.create(step);
    element=element.withInsertHandler(new InsertHandler<LookupElement>(){
      @Override public void handleInsert(      InsertionContext context,      LookupElement item){
        PsiElement stepElement=context.getFile().findElementAt(context.getStartOffset()).getParent();
        final TemplateBuilder builder=TemplateBuilderFactory.getInstance().createTemplateBuilder(stepElement);
        List<SpecArg> args=PsiTreeUtil.getChildrenOfTypeAsList(stepElement,SpecArg.class);
        for (        SpecArg arg : args) {
          builder.replaceRange(getRangeWithinElement(arg),arg.getText());
        }
        builder.run(context.getEditor(),false);
      }
    }
);
    resultSet.addElement(element);
  }
}

Fixed version (ground truth):
public void addCompletions(@NotNull CompletionParameters parameters,ProcessingContext context,@NotNull CompletionResultSet resultSet){
  resultSet.stopHere();
  String prefix=getPrefix(parameters);
  resultSet=resultSet.withPrefixMatcher(new PlainPrefixMatcher(prefix));
  Module moduleForPsiElement=ModuleUtil.findModuleForPsiElement(parameters.getPosition());
  if (moduleForPsiElement == null) {
    return;
  }
  for (  String step : getStepsInModule(moduleForPsiElement)) {
    LookupElementBuilder element=LookupElementBuilder.create(step);
    element=element.withInsertHandler(new InsertHandler<LookupElement>(){
      @Override public void handleInsert(      InsertionContext context,      LookupElement item){
        PsiElement stepElement=context.getFile().findElementAt(context.getStartOffset()).getParent();
        final TemplateBuilder builder=TemplateBuilderFactory.getInstance().createTemplateBuilder(stepElement);
        List<SpecArg> args=PsiTreeUtil.getChildrenOfTypeAsList(stepElement,SpecArg.class);
        for (        SpecArg arg : args) {
          builder.replaceRange(getRangeWithinElement(arg),arg.getText());
        }
        builder.run(context.getEditor(),false);
      }
    }
);
    resultSet.addElement(element);
  }
}
Program: 86444
Project: 86444
Buggy source:
@NotNull @Override protected ProcessHandler startProcess() throws ExecutionException {
  GeneralCommandLine commandLine=new GeneralCommandLine();
  commandLine.setExePath(GAUGE);
  commandLine.addParameter(SIMPLE_CONSOLE_FLAG);
  commandLine.setWorkDirectory(getProject().getBaseDir().getPath());
  if (!Strings.isBlank(environment)) {
    commandLine.addParameters(ENV_FLAG,environment);
  }
  commandLine.addParameter(specsToExecute);
  if (DefaultDebugExecutor.EXECUTOR_ID.equals(env.getExecutor().getId())) {
    commandLine.getEnvironment().put(GAUGE_DEBUG_OPTS_ENV,JAVA_DEBUG_PORT);
  }
  return GaugeRunProcessHandler.runCommandLine(commandLine);
}

Fixed version (ground truth):
@NotNull @Override protected ProcessHandler startProcess() throws ExecutionException {
  GeneralCommandLine commandLine=new GeneralCommandLine();
  commandLine.setExePath(GaugeUtil.getGaugeExecPath());
  commandLine.addParameter(SIMPLE_CONSOLE_FLAG);
  commandLine.setWorkDirectory(getProject().getBaseDir().getPath());
  if (!Strings.isBlank(environment)) {
    commandLine.addParameters(ENV_FLAG,environment);
  }
  commandLine.addParameter(specsToExecute);
  if (DefaultDebugExecutor.EXECUTOR_ID.equals(env.getExecutor().getId())) {
    commandLine.getEnvironment().put(GAUGE_DEBUG_OPTS_ENV,JAVA_DEBUG_PORT);
  }
  return GaugeRunProcessHandler.runCommandLine(commandLine);
}
Program: 86445
Project: 86445
Buggy source:
@Nullable @Override public RunProfileState getState(@NotNull Executor executor,@NotNull final ExecutionEnvironment env) throws ExecutionException {
  return new CommandLineState(env){
    @NotNull @Override protected ProcessHandler startProcess() throws ExecutionException {
      GeneralCommandLine commandLine=new GeneralCommandLine();
      commandLine.setExePath(GAUGE);
      commandLine.addParameter(SIMPLE_CONSOLE_FLAG);
      commandLine.setWorkDirectory(getProject().getBaseDir().getPath());
      if (!Strings.isBlank(environment)) {
        commandLine.addParameters(ENV_FLAG,environment);
      }
      commandLine.addParameter(specsToExecute);
      if (DefaultDebugExecutor.EXECUTOR_ID.equals(env.getExecutor().getId())) {
        commandLine.getEnvironment().put(GAUGE_DEBUG_OPTS_ENV,JAVA_DEBUG_PORT);
      }
      return GaugeRunProcessHandler.runCommandLine(commandLine);
    }
  }
;
}

Fixed version (ground truth):
@Nullable @Override public RunProfileState getState(@NotNull Executor executor,@NotNull final ExecutionEnvironment env) throws ExecutionException {
  return new CommandLineState(env){
    @NotNull @Override protected ProcessHandler startProcess() throws ExecutionException {
      GeneralCommandLine commandLine=new GeneralCommandLine();
      commandLine.setExePath(GaugeUtil.getGaugeExecPath());
      commandLine.addParameter(SIMPLE_CONSOLE_FLAG);
      commandLine.setWorkDirectory(getProject().getBaseDir().getPath());
      if (!Strings.isBlank(environment)) {
        commandLine.addParameters(ENV_FLAG,environment);
      }
      commandLine.addParameter(specsToExecute);
      if (DefaultDebugExecutor.EXECUTOR_ID.equals(env.getExecutor().getId())) {
        commandLine.getEnvironment().put(GAUGE_DEBUG_OPTS_ENV,JAVA_DEBUG_PORT);
      }
      return GaugeRunProcessHandler.runCommandLine(commandLine);
    }
  }
;
}
Program: 86446
Project: 86446
Buggy source:
ItemStack[] getAcceptableFlowers(String flowerType);

Fixed version (ground truth):
List<IFlower> getAcceptableFlowers(String flowerType);
Program: 86447
Project: 86447
Buggy source:
ItemStack getRandomPlantableFlower(String flowerType,Random rand);

Fixed version (ground truth):
IFlower getRandomPlantableFlower(String flowerType,Random rand);
Program: 86448
Project: 86448
Buggy source:
/** 
 * Registers a plantable flower. The distribution is based on its own weight and the total number of plants for this flowerType.
 * @param weight Weight for the Flower (Vanilla = 1.0, Modded flowers < 1.0)
 * @param flowerTypes See {@link forestry.api.apiculture.FlowerManager}.FlowerTypeXXX
 */
void registerPlantableFlower(ItemStack flower,double weight,String... flowerTypes);

Fixed version (ground truth):
/** 
 * Registers a plantable flower. The distribution is based on its own weight and the total number of plants for this flowerType.
 * @param weight Weight for the Flower (Vanilla = 1.0, Modded flowers < 1.0)
 * @param flowerTypes See {@link forestry.api.apiculture.FlowerManager}.FlowerTypeXXX
 */
void registerPlantableFlower(Block flowerBlock,int flowerMeta,double weight,String... flowerTypes);
Program: 86449
Project: 86449
Buggy source:
/** 
 * Registers a non-plantable flower, but bees accept them.
 * @param flowerTypes See {@link forestry.api.apiculture.FlowerManager}.FlowerTypeXXX
 */
void registerAcceptableFlower(ItemStack flower,String... flowerTypes);

Fixed version (ground truth):
/** 
 * Registers a non-plantable flower, but bees accept them.
 * @param flowerTypes See {@link forestry.api.apiculture.FlowerManager}.FlowerTypeXXX
 */
void registerAcceptableFlower(Block flowerBlock,int flowerMeta,String... flowerTypes);
Program: 86451
Project: 86451
Buggy source:
public static String getDeployedRevision(ServerProfile profile) throws IOException {
  BundleDeploymentConfig deployment1=null;
  try {
    HttpRequest restRequest=REQUEST_FACTORY.buildGetRequest(new GenericUrl(profile.getHostUrl() + "String_Node_Str" + profile.getApi_version()+ "String_Node_Str"+ profile.getOrg()+ "String_Node_Str"+ profile.getApplication()+ "String_Node_Str"));
    restRequest.setReadTimeout(0);
    HttpHeaders headers=new HttpHeaders();
    headers.setAccept("String_Node_Str");
    headers.setBasicAuthentication(profile.getCredential_user(),profile.getCredential_pwd());
    restRequest.setHeaders(headers);
    logger.debug(PrintUtil.formatRequest(restRequest));
    HttpResponse response=restRequest.execute();
    deployment1=response.parseAs(BundleDeploymentConfig.class);
    logger.debug(PrintUtil.formatResponse(response,gson.toJson(deployment1).toString()));
    if (deployment1 != null) {
      for (      Environment env : deployment1.environment) {
        if (env.name.equalsIgnoreCase(profile.getEnvironment()))         return env.revision.get(0).name;
      }
    }
  }
 catch (  HttpResponseException e) {
    logger.error(e.getMessage());
  }
catch (  Exception e) {
    logger.error(e.getMessage());
  }
  return "String_Node_Str";
}

Fixed version (ground truth):
public static String getDeployedRevision(ServerProfile profile) throws IOException {
  BundleDeploymentConfig deployment1=null;
  try {
    HttpRequest restRequest=REQUEST_FACTORY.buildGetRequest(new GenericUrl(profile.getHostUrl() + "String_Node_Str" + profile.getApi_version()+ "String_Node_Str"+ profile.getOrg()+ "String_Node_Str"+ profile.getApplication()+ "String_Node_Str"));
    restRequest.setReadTimeout(0);
    HttpHeaders headers=new HttpHeaders();
    headers.setAccept("String_Node_Str");
    headers.setBasicAuthentication(profile.getCredential_user(),profile.getCredential_pwd());
    restRequest.setHeaders(headers);
    logger.debug(PrintUtil.formatRequest(restRequest));
    HttpResponse response=restRequest.execute();
    deployment1=response.parseAs(BundleDeploymentConfig.class);
    logger.debug(PrintUtil.formatResponse(response,gson.toJson(deployment1).toString()));
    if (deployment1 != null) {
      for (      Environment env : deployment1.environment) {
        if (env.name.equalsIgnoreCase(profile.getEnvironment())) {
          List<Revision> revisionList=env.revision;
          if (revisionList != null && revisionList.size() > 0) {
            List<String> revisions=new ArrayList<String>();
            for (            Revision revision : revisionList) {
              revisions.add(revision.name);
            }
            Collections.sort(revisions,new StringToIntComparator());
            return revisions.get(0);
          }
        }
      }
    }
  }
 catch (  HttpResponseException e) {
    logger.error(e.getMessage());
  }
catch (  Exception e) {
    logger.error(e.getMessage());
  }
  return "String_Node_Str";
}
Program: 86454
Project: 86454
Buggy source:
public static Document replaceTokens(Document doc,Policy configTokens) throws XPathExpressionException, TransformerConfigurationException {
  Logger logger=LoggerFactory.getLogger(PackageConfigurer.class);
  javax.xml.xpath.XPathFactory factory=javax.xml.xpath.XPathFactory.newInstance();
  javax.xml.xpath.XPath xpath=factory.newXPath();
  Gson gson=new GsonBuilder().setPrettyPrinting().create();
  String json=gson.toJson(configTokens);
  logger.info("String_Node_Str",json);
  try {
    for (int i=0; i < configTokens.tokens.size(); i++) {
      logger.debug("String_Node_Str",configTokens.tokens.get(i).xpath);
      javax.xml.xpath.XPathExpression expression=xpath.compile(configTokens.tokens.get(i).xpath);
      NodeList nodes=(NodeList)expression.evaluate(doc,XPathConstants.NODESET);
      for (int j=0; j < nodes.getLength(); j++) {
        if (nodes.item(j).hasChildNodes()) {
          logger.debug("String_Node_Str",nodes.item(j).getTextContent(),configTokens.tokens.get(i).value);
          nodes.item(j).setTextContent(configTokens.tokens.get(i).value);
        }
      }
    }
    return doc;
  }
 catch (  Exception e) {
    logger.error("String_Node_Str",e.getMessage());
    throw (XPathExpressionException)e;
  }
}

Fixed version (ground truth):
public static Document replaceTokens(Document doc,Policy configTokens) throws XPathExpressionException, TransformerConfigurationException {
  Logger logger=LoggerFactory.getLogger(PackageConfigurer.class);
  javax.xml.xpath.XPathFactory factory=javax.xml.xpath.XPathFactory.newInstance();
  javax.xml.xpath.XPath xpath=factory.newXPath();
  Gson gson=new GsonBuilder().setPrettyPrinting().create();
  String json=gson.toJson(configTokens);
  logger.info("String_Node_Str",json);
  try {
    for (int i=0; i < configTokens.tokens.size(); i++) {
      logger.debug("String_Node_Str",configTokens.tokens.get(i).xpath);
      javax.xml.xpath.XPathExpression expression=xpath.compile(configTokens.tokens.get(i).xpath);
      NodeList nodes=(NodeList)expression.evaluate(doc,XPathConstants.NODESET);
      for (int j=0; j < nodes.getLength(); j++) {
        if (nodes.item(j).getNodeName() != null && !nodes.item(j).getNodeName().equals("String_Node_Str")) {
          logger.debug("String_Node_Str",nodes.item(j).getTextContent(),configTokens.tokens.get(i).value);
          nodes.item(j).setTextContent(configTokens.tokens.get(i).value);
        }
      }
    }
    return doc;
  }
 catch (  Exception e) {
    logger.error("String_Node_Str",e.getMessage());
    throw (XPathExpressionException)e;
  }
}
Program: 86456
Project: 86456
Buggy source:
@Override public boolean onPrepareOptionsMenu(Menu menu){
  menu.findItem(R.id.action_settings).setEnabled(menuBool);
  return true;
}

Fixed version (ground truth):
@Override public boolean onPrepareOptionsMenu(Menu menu){
  menu.findItem(R.id.action_settings).setVisible(false);
  return true;
}
Program: 86458
Project: 86458
Buggy source:
@Override protected void onDestroy(){
  super.onDestroy();
}

Fixed version (ground truth):
@Override protected void onDestroy(){
  super.onDestroy();
  DataHandler.getInstance().deleteObserver(this);
}
Program: 86459
Project: 86459
Buggy source:
/** 
 * Called when bluetooth connection failed
 */
public void connectionError(){
  menuBool=false;
  runOnUiThread(new Runnable(){
    public void run(){
      Toast.makeText(getBaseContext(),getString(R.string.couldnotconnect),Toast.LENGTH_SHORT).show();
      TextView rpm=(TextView)findViewById(R.id.rpm);
      rpm.setText("String_Node_Str");
      Spinner spinner1=(Spinner)findViewById(R.id.spinner1);
      spinner1.setSelection(0);
    }
  }
);
}

Fixed version (ground truth):
/** 
 * Called when bluetooth connection failed
 */
public void connectionError(){
  menuBool=false;
  runOnUiThread(new Runnable(){
    public void run(){
      Toast.makeText(getBaseContext(),getString(R.string.couldnotconnect),Toast.LENGTH_SHORT).show();
      TextView rpm=(TextView)findViewById(R.id.rpm);
      rpm.setText("String_Node_Str");
      Spinner spinner1=(Spinner)findViewById(R.id.spinner1);
      spinner1.setSelection(DataHandler.getInstance().getID());
    }
  }
);
}
Program: 86460
Project: 86460
Buggy source:
public void run(){
  menuBool=true;
  TextView rpm=(TextView)findViewById(R.id.rpm);
  rpm.setText(DataHandler.getInstance().getLastValue() + "String_Node_Str");
  if (DataHandler.getInstance().getLastValue() != 0) {
    series1.addLast(0,DataHandler.getInstance().getLastValue());
    plot.redraw();
  }
  TextView min=(TextView)findViewById(R.id.min);
  min.setText("String_Node_Str" + DataHandler.getInstance().getMin() + "String_Node_Str");
  TextView max=(TextView)findViewById(R.id.max);
  max.setText("String_Node_Str" + DataHandler.getInstance().getMax() + "String_Node_Str");
}

Fixed version (ground truth):
public void run(){
  menuBool=true;
  TextView rpm=(TextView)findViewById(R.id.rpm);
  rpm.setText(DataHandler.getInstance().getLastValue() + "String_Node_Str");
  if (DataHandler.getInstance().getLastValue() != 0) {
    DataHandler.getInstance().getSeries1().addLast(0,DataHandler.getInstance().getLastValue());
    plot.redraw();
  }
  TextView min=(TextView)findViewById(R.id.min);
  min.setText("String_Node_Str" + DataHandler.getInstance().getMin() + "String_Node_Str");
  TextView max=(TextView)findViewById(R.id.max);
  max.setText("String_Node_Str" + DataHandler.getInstance().getMax() + "String_Node_Str");
}
Program: 86461
Project: 86461
Buggy source:
/** 
 * When menu button are pressed
 */
public boolean onOptionsItemSelected(MenuItem item){
  int id=item.getItemId();
  if (id == R.id.action_settings) {
    reader.cancel();
    System.out.println("String_Node_Str");
    menuBool=false;
    return true;
  }
 else   if (id == R.id.about) {
    Intent intent=new Intent(this,AboutActivity.class);
    startActivity(intent);
  }
  return super.onOptionsItemSelected(item);
}

Fixed version (ground truth):
/** 
 * When menu button are pressed
 */
public boolean onOptionsItemSelected(MenuItem item){
  int id=item.getItemId();
  if (id == R.id.action_settings) {
    DataHandler.getInstance().getReader().cancel();
    System.out.println("String_Node_Str");
    menuBool=false;
    return true;
  }
 else   if (id == R.id.about) {
    Intent intent=new Intent(this,AboutActivity.class);
    startActivity(intent);
  }
  return super.onOptionsItemSelected(item);
}
Program: 86462
Project: 86462
Buggy source:
@Override public void onItemSelected(AdapterView<?> arg0,View arg1,int arg2,long arg3){
  if (arg2 != 0) {
    t.setScreenName("String_Node_Str");
    t.send(new HitBuilders.AppViewBuilder().build());
    reader=new ConnectThread((BluetoothDevice)pairedDevices.toArray()[arg2 - 1],this);
    reader.start();
    menuBool=true;
  }
}

Fixed version (ground truth):
@Override public void onItemSelected(AdapterView<?> arg0,View arg1,int arg2,long arg3){
  if (arg2 != 0) {
    DataHandler.getInstance().setID(arg2);
    DataHandler.getInstance().setReader(new ConnectThread((BluetoothDevice)pairedDevices.toArray()[arg2 - 1],this));
    DataHandler.getInstance().getReader().start();
    menuBool=true;
  }
}
Program: 86463
Project: 86463
Buggy source:
/** 
 * Update Gui with new value from receiver
 */
public void receiveData(){
  runOnUiThread(new Runnable(){
    public void run(){
      menuBool=true;
      TextView rpm=(TextView)findViewById(R.id.rpm);
      rpm.setText(DataHandler.getInstance().getLastValue() + "String_Node_Str");
      if (DataHandler.getInstance().getLastValue() != 0) {
        series1.addLast(0,DataHandler.getInstance().getLastValue());
        plot.redraw();
      }
      TextView min=(TextView)findViewById(R.id.min);
      min.setText("String_Node_Str" + DataHandler.getInstance().getMin() + "String_Node_Str");
      TextView max=(TextView)findViewById(R.id.max);
      max.setText("String_Node_Str" + DataHandler.getInstance().getMax() + "String_Node_Str");
    }
  }
);
}

Fixed version (ground truth):
/** 
 * Update Gui with new value from receiver
 */
public void receiveData(){
  t.setScreenName("String_Node_Str");
  t.send(new HitBuilders.AppViewBuilder().build());
  runOnUiThread(new Runnable(){
    public void run(){
      menuBool=true;
      TextView rpm=(TextView)findViewById(R.id.rpm);
      rpm.setText(DataHandler.getInstance().getLastValue() + "String_Node_Str");
      if (DataHandler.getInstance().getLastValue() != 0) {
        DataHandler.getInstance().getSeries1().addLast(0,DataHandler.getInstance().getLastValue());
        plot.redraw();
      }
      TextView min=(TextView)findViewById(R.id.min);
      min.setText("String_Node_Str" + DataHandler.getInstance().getMin() + "String_Node_Str");
      TextView max=(TextView)findViewById(R.id.max);
      max.setText("String_Node_Str" + DataHandler.getInstance().getMax() + "String_Node_Str");
    }
  }
);
}
Program: 86464
Project: 86464
Buggy source:
/** 
 * Run on startup to list bluetooth paired device
 */
public void listBT(){
  if (searchBt) {
    List<String> list=new ArrayList<String>();
    list.add("String_Node_Str");
    pairedDevices=mBluetoothAdapter.getBondedDevices();
    if (pairedDevices.size() > 0) {
      for (      BluetoothDevice device : pairedDevices) {
        list.add(device.getName() + "String_Node_Str" + device.getAddress());
      }
    }
    Spinner spinner1=(Spinner)findViewById(R.id.spinner1);
    ArrayAdapter<String> dataAdapter=new ArrayAdapter<String>(this,android.R.layout.simple_spinner_item,list);
    dataAdapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
    spinner1.setOnItemSelectedListener(this);
    spinner1.setAdapter(dataAdapter);
  }
}

Fixed version (ground truth):
/** 
 * Run on startup to list bluetooth paired device
 */
public void listBT(){
  if (searchBt) {
    List<String> list=new ArrayList<String>();
    list.add("String_Node_Str");
    pairedDevices=mBluetoothAdapter.getBondedDevices();
    if (pairedDevices.size() > 0) {
      for (      BluetoothDevice device : pairedDevices) {
        list.add(device.getName() + "String_Node_Str" + device.getAddress());
      }
    }
    Spinner spinner1=(Spinner)findViewById(R.id.spinner1);
    ArrayAdapter<String> dataAdapter=new ArrayAdapter<String>(this,android.R.layout.simple_spinner_item,list);
    dataAdapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
    spinner1.setOnItemSelectedListener(this);
    spinner1.setAdapter(dataAdapter);
    if (DataHandler.getInstance().getID() != 0)     spinner1.setSelection(DataHandler.getInstance().getID());
  }
}
Program: 86465
Project: 86465
Buggy source:
public void run(){
  try {
    if (mmSocket.isConnected())     mmSocket.close();
    mmSocket.connect();
  }
 catch (  IOException connectException) {
    ac.connectionError();
    Log.d("String_Node_Str",connectException.toString());
    try {
      mmSocket.close();
    }
 catch (    IOException closeException) {
    }
    return;
  }
  while (true) {
    try {
      DataHandler.getInstance().acqui(mmSocket.getInputStream().read());
    }
 catch (    IOException e) {
      ac.connectionError();
      Log.d("String_Node_Str",e.toString());
      try {
        mmSocket.getInputStream().close();
        mmSocket.close();
      }
 catch (      IOException closeException) {
      }
      return;
    }
  }
}

Fixed version (ground truth):
public void run(){
  int ok=0;
  while (ok < 2)   try {
    if (mmSocket.isConnected())     mmSocket.close();
    mmSocket.connect();
    ok=5;
  }
 catch (  IOException connectException) {
    if (ok == 0)     ok++;
 else {
      ac.connectionError();
      Log.d("String_Node_Str",connectException.toString());
      try {
        mmSocket.close();
      }
 catch (      IOException closeException) {
      }
      return;
    }
  }
  while (true) {
    try {
      DataHandler.getInstance().acqui(mmSocket.getInputStream().read());
    }
 catch (    IOException e) {
      ac.connectionError();
      Log.d("String_Node_Str",e.toString());
      try {
        mmSocket.getInputStream().close();
        mmSocket.close();
      }
 catch (      IOException closeException) {
      }
      return;
    }
  }
}
Program: 86467
Project: 86467
Buggy source:
public Date getCreatedAt(){
  return createdAt;
}

Fixed version (ground truth):
public String getCreatedAt(){
  return createdAt;
}
Program: 86468
Project: 86468
Buggy source:
@Override public String toString(){
  return new StringBuilder().append('{').append("String_Node_Str").append(selfHref).append("String_Node_Str").append("String_Node_Str").append(hostedAccountHref).append("String_Node_Str").append('}').toString();
}

Fixed version (ground truth):
@Override public String toString(){
  return new StringBuilder().append('{').append("String_Node_Str").append(self).append("String_Node_Str").append("String_Node_Str").append(hostedAccount).append("String_Node_Str").append('}').toString();
}
Program: 86469
Project: 86469
Buggy source:
public String getHostedAccountHref(){
  return hostedAccountHref.redirectHref;
}

Fixed version (ground truth):
public String getHostedAccountHref(){
  return hostedAccount.getRedirectHref();
}
Program: 86470
Project: 86470
Buggy source:
public String getSelfHref(){
  return selfHref.href;
}

Fixed version (ground truth):
public String getSelfHref(){
  return self.getHref();
}
Program: 86472
Project: 86472
Buggy source:
public String getAuthorizeUrl(String clientId,String redirectUri,ScopePermissionList scope){
  try {
    URIBuilder b=new URIBuilder(Client.CONNECT_SANDBOX + "String_Node_Str");
    b.addParameter("String_Node_Str","String_Node_Str");
    b.addParameter("String_Node_Str",clientId);
    b.addParameter("String_Node_Str",redirectUri);
    b.addParameter("String_Node_Str",scope.toString());
    URL url=b.build().toURL();
    return url.toString();
  }
 catch (  URISyntaxException e) {
    throw new MoipException("String_Node_Str" + e.getMessage());
  }
catch (  MalformedURLException e) {
    throw new MoipException("String_Node_Str" + e.getMessage());
  }
}

Fixed version (ground truth):
public String getAuthorizeUrl(String clientId,String redirectUri,ScopePermissionList scope){
  try {
    URIBuilder b=new URIBuilder(client.getEndpoint() + "String_Node_Str");
    b.addParameter("String_Node_Str","String_Node_Str");
    b.addParameter("String_Node_Str",clientId);
    b.addParameter("String_Node_Str",redirectUri);
    b.addParameter("String_Node_Str",scope.toString());
    URL url=b.build().toURL();
    return url.toString();
  }
 catch (  URISyntaxException e) {
    throw new MoipException("String_Node_Str" + e.getMessage());
  }
catch (  MalformedURLException e) {
    throw new MoipException("String_Node_Str" + e.getMessage());
  }
}
Program: 86473
Project: 86473
Buggy source:
@Test public void testGetAuthURL(){
  String authURL=api.getAuthorizeUrl("String_Node_Str","String_Node_Str",new ScopePermissionList(ScopePermission.DEFINE_PREFERENCES,ScopePermission.MANAGE_ACCOUNT_INFO,ScopePermission.RECEIVE_FUNDS,ScopePermission.REFUND,ScopePermission.RETRIEVE_FINANCIAL_INFO,ScopePermission.TRANSFER_FUNDS));
  assertEquals("String_Node_Str",authURL);
}

Fixed version (ground truth):
@Test public void testGetAuthURL(){
  api=new ConnectAPI(new ClientFactory().client(Client.CONNECT_SANDBOX));
  String authURL=api.getAuthorizeUrl("String_Node_Str","String_Node_Str",new ScopePermissionList(ScopePermission.DEFINE_PREFERENCES,ScopePermission.MANAGE_ACCOUNT_INFO,ScopePermission.RECEIVE_FUNDS,ScopePermission.REFUND,ScopePermission.RETRIEVE_FINANCIAL_INFO,ScopePermission.TRANSFER_FUNDS));
  assertEquals("String_Node_Str",authURL);
}
Program: 86474
Project: 86474
Buggy source:
public Invoice get(final String id){
  Invoice invoice=client.get("String_Node_Str" + id,Invoice.class);
  return invoice;
}

Fixed version (ground truth):
public Invoice get(final String id){
  return client.get("String_Node_Str" + id,Invoice.class);
}
Program: 86475
Project: 86475
Buggy source:
public Invoice create(final InvoiceRequest invoice){
  Invoice createdInvoice=client.post("String_Node_Str",invoice,Invoice.class);
  return createdInvoice;
}

Fixed version (ground truth):
public Invoice create(final InvoiceRequest invoice){
  return client.post("String_Node_Str",invoice,Invoice.class);
}
Program: 86476
Project: 86476
Buggy source:
public Invoice list(){
  Invoice createdInvoice=client.get("String_Node_Str",Invoice.class);
  return createdInvoice;
}

Fixed version (ground truth):
public List<Invoice> list(){
  return client.get("String_Node_Str",new ArrayList<Invoice>().getClass());
}
Program: 86477
Project: 86477
Buggy source:
@Override public String toString(){
  final StringBuilder sb=new StringBuilder("String_Node_Str");
  sb.append("String_Node_Str").append(method);
  sb.append("String_Node_Str").append(creditCard);
  sb.append('}');
  return sb.toString();
}

Fixed version (ground truth):
@Override public String toString(){
  final StringBuilder sb=new StringBuilder("String_Node_Str");
  sb.append("String_Node_Str").append(method);
  sb.append("String_Node_Str").append(creditCard);
  sb.append("String_Node_Str").append(boleto);
  sb.append('}');
  return sb.toString();
}
Program: 86479
Project: 86479
Buggy source:
/** 
 * Use of this method assumes the path given matches this Route.
 */
public String[] splat(String path){
  List<SplatParameterElement> splatParams=getSplatParameterElements();
  String[] pathTokens=RouteHelper.getPathElements(path);
  String[] splat=new String[splatParams.size()];
  for (int i=0; i < splatParams.size(); i++) {
    SplatParameterElement splatParam=splatParams.get(i);
    splat[i]=urlDecodeForPathParams(pathTokens[splatParam.index()]);
    if (i + 1 == splatParams.size() && endsWithSplat()) {
      for (int j=splatParam.index() + 1; j < pathTokens.length; j++) {
        splat[i]=splat[i] + PATH_ELEMENT_SEPARATOR + urlDecodeForPathParams(pathTokens[j]);
      }
    }
  }
  return splat;
}

Fixed version (ground truth):
/** 
 * Use of this method assumes the path given matches this Route.
 */
public String[] splat(String path){
  List<SplatParameterElement> splatParams=getSplatParameterElements();
  String[] pathTokens=RouteHelper.getPathElements(path,false);
  String[] splat=new String[splatParams.size()];
  for (int i=0; i < splatParams.size(); i++) {
    SplatParameterElement splatParam=splatParams.get(i);
    splat[i]=urlDecodeForPathParams(pathTokens[splatParam.index()]);
    if (i + 1 == splatParams.size() && endsWithSplat()) {
      for (int j=splatParam.index() + 1; j < pathTokens.length; j++) {
        splat[i]=splat[i] + PATH_ELEMENT_SEPARATOR + urlDecodeForPathParams(pathTokens[j]);
      }
    }
  }
  return splat;
}
Program: 86480
Project: 86480
Buggy source:
public static String[] getPathElements(String path){
  if (path == null)   throw new IllegalArgumentException("String_Node_Str");
  path=path.trim();
  if (path.length() == 0)   throw new IllegalArgumentException("String_Node_Str");
  path=path.startsWith(PATH_ELEMENT_SEPARATOR) ? path.substring(1) : path;
  return path.split(PATH_ELEMENT_SEPARATOR);
}

Fixed version (ground truth):
public static String[] getPathElements(String path,boolean ignoreTrailingSeparator){
  if (path == null)   throw new IllegalArgumentException("String_Node_Str");
  path=path.trim();
  if (path.length() == 0)   throw new IllegalArgumentException("String_Node_Str");
  path=path.startsWith(PATH_ELEMENT_SEPARATOR) ? path.substring(1) : path;
  return path.split(PATH_ELEMENT_SEPARATOR,ignoreTrailingSeparator ? 0 : -1);
}
Program: 86481
Project: 86481
Buggy source:
private void sendPacket(byte opCode,Closure closure) throws IOException {
  socketWait.addAndGet(1);
synchronized (socketOut) {
    sendByte(opCode);
    closure.run();
  }
  if (socketWait.addAndGet(-1) == 0) {
    socketOut.flush();
  }
}

Fixed version (ground truth):
private void sendPacket(byte opCode,Closure closure) throws IOException {
  socketWait.incrementAndGet();
synchronized (socketOut) {
    sendByte(opCode);
    closure.run();
  }
  if (socketWait.decrementAndGet() == 0) {
    socketOut.flush();
  }
}
Program: 86482
Project: 86482
Buggy source:
public RelayProtocol(final int port,final String cluster) throws IOException {
  socket=new Socket(InetAddress.getLoopbackAddress(),port);
  socketIn=new DataInputStream(new BufferedInputStream(socket.getInputStream()));
  socketOut=new DataOutputStream(new BufferedOutputStream(socket.getOutputStream()));
  socketWait=new AtomicInteger();
  sendInit(cluster);
  processInit();
}

Fixed version (ground truth):
public RelayProtocol(final int port,final String cluster) throws IOException {
  socket=new Socket(InetAddress.getLoopbackAddress(),port);
  socket.setTcpNoDelay(true);
  socketIn=new DataInputStream(new BufferedInputStream(socket.getInputStream()));
  socketOut=new DataOutputStream(new BufferedOutputStream(socket.getOutputStream()));
  socketWait=new AtomicInteger();
  sendInit(cluster);
  processInit();
}
Program: 86483
Project: 86483
Buggy source:
public byte[] receive(final long timeout) throws InterruptedException, TimeoutException {
synchronized (itoaBuffer) {
    if (itoaBuffer.isEmpty()) {
      if (timeout > 0) {
        itoaBuffer.wait(timeout);
      }
 else {
        itoaBuffer.wait();
      }
      if (itoaBuffer.isEmpty()) {
        throw new TimeoutException("String_Node_Str");
      }
    }
    final byte[] message=itoaBuffer.remove();
    throttler.execute(() -> {
      try {
        protocol.sendTunnelAllowance(id,message.length);
      }
 catch (      IOException ignored) {
      }
    }
);
    return message;
  }
}

Fixed version (ground truth):
public byte[] receive(final long timeout) throws InterruptedException, TimeoutException {
synchronized (itoaBuffer) {
    if (itoaBuffer.isEmpty()) {
      if (timeout > 0) {
        itoaBuffer.wait(timeout);
      }
 else {
        itoaBuffer.wait();
      }
      if (itoaBuffer.isEmpty()) {
        throw new TimeoutException("String_Node_Str");
      }
    }
    final byte[] message=itoaBuffer.remove();
    throttler.submit(() -> {
      try {
        protocol.sendTunnelAllowance(id,message.length);
      }
 catch (      IOException ignored) {
      }
    }
);
    return message;
  }
}
Program: 86484
Project: 86484
Buggy source:
public void handleTransfer(final int size,final byte[] chunk){
  if (size != 0) {
    if (chunkBuffer != null) {
      logger.loadContext();
      logger.warn("String_Node_Str","String_Node_Str",String.valueOf(chunkCapacity),"String_Node_Str",String.valueOf(chunkBuffer.size()));
      logger.unloadContext();
      final int allowance=chunkBuffer.size();
      throttler.execute(() -> {
        try {
          protocol.sendTunnelAllowance(id,allowance);
        }
 catch (        IOException ignored) {
        }
      }
);
    }
    chunkCapacity=size;
    chunkBuffer=new ByteArrayOutputStream(chunkCapacity);
  }
  try {
    chunkBuffer.write(chunk);
  }
 catch (  IOException ignored) {
  }
  if (chunkBuffer.size() == chunkCapacity) {
synchronized (itoaBuffer) {
      itoaBuffer.add(chunkBuffer.toByteArray());
      chunkBuffer=null;
      chunkCapacity=0;
      itoaBuffer.notify();
    }
  }
}

Fixed version (ground truth):
public void handleTransfer(final int size,final byte[] chunk){
  if (size != 0) {
    if (chunkBuffer != null) {
      logger.loadContext();
      logger.warn("String_Node_Str","String_Node_Str",String.valueOf(chunkCapacity),"String_Node_Str",String.valueOf(chunkBuffer.size()));
      logger.unloadContext();
      final int allowance=chunkBuffer.size();
      throttler.submit(() -> {
        try {
          protocol.sendTunnelAllowance(id,allowance);
        }
 catch (        IOException ignored) {
        }
      }
);
    }
    chunkCapacity=size;
    chunkBuffer=new ByteArrayOutputStream(chunkCapacity);
  }
  try {
    chunkBuffer.write(chunk);
  }
 catch (  IOException ignored) {
  }
  if (chunkBuffer.size() == chunkCapacity) {
synchronized (itoaBuffer) {
      itoaBuffer.add(chunkBuffer.toByteArray());
      chunkBuffer=null;
      chunkCapacity=0;
      itoaBuffer.notify();
    }
  }
}
Program: 86485
Project: 86485
Buggy source:
Connection(int port,@NotNull String cluster,@Nullable ServiceHandler handler,@Nullable ServiceLimits limits) throws IOException {
  Validators.validateClusterName(cluster);
  if (limits == null) {
    limits=new ServiceLimits();
  }
  protocol=new RelayProtocol(port,cluster);
  broadcaster=new BroadcastScheme(protocol,handler,limits);
  requester=new RequestScheme(protocol,handler,limits);
  subscriber=new PublishScheme(protocol);
  tunneler=new TunnelScheme(protocol,handler);
  runner=new Thread(() -> protocol.process(handler,broadcaster,requester,subscriber,tunneler));
  runner.start();
}

Fixed version (ground truth):
Connection(final int port,final String cluster,final ServiceHandler handler,final ServiceLimits limits,final ContextualLogger logger) throws IOException {
  Validators.validateClusterName(cluster);
  this.logger=logger;
  protocol=new RelayProtocol(port,cluster);
  broadcaster=new BroadcastScheme(protocol,handler,limits,logger);
  requester=new RequestScheme(protocol,handler,limits,logger);
  subscriber=new PublishScheme(protocol,logger);
  tunneler=new TunnelScheme(protocol,handler,logger);
  runner=new Thread(() -> protocol.process(handler,broadcaster,requester,subscriber,tunneler));
  runner.start();
}
Program: 86486
Project: 86486
Buggy source:
@Override public void close() throws IOException, InterruptedException {
  protocol.sendClose();
  runner.join();
  tunneler.close();
  subscriber.close();
  requester.close();
  broadcaster.close();
}

Fixed version (ground truth):
@Override public void close() throws IOException, InterruptedException {
  logger.loadContext();
  try {
    logger.info("String_Node_Str");
    protocol.sendClose();
    runner.join();
    tunneler.close();
    subscriber.close();
    requester.close();
    broadcaster.close();
  }
  finally {
    logger.unloadContext();
  }
}
Program: 86487
Project: 86487
Buggy source:
public static Connection connect(final int port) throws IOException {
  return new Connection(port,"String_Node_Str",null,null);
}

Fixed version (ground truth):
public static Connection connect(final int port) throws IOException {
  final ContextualLogger logger=new ContextualLogger(LoggerFactory.getLogger(Iris.class.getPackage().getName()),"String_Node_Str",String.valueOf(nextConnId.incrementAndGet()));
  try {
    logger.loadContext();
    logger.info("String_Node_Str","String_Node_Str",String.valueOf(port));
    final Connection conn=new Connection(port,"String_Node_Str",null,null,logger);
    logger.info("String_Node_Str");
    return conn;
  }
 catch (  IOException e) {
    logger.warn("String_Node_Str","String_Node_Str",e.getMessage());
    throw e;
  }
 finally {
    logger.unloadContext();
  }
}
Program: 86488
Project: 86488
Buggy source:
public static Service register(final int port,@NotNull final String cluster,@NotNull final ServiceHandler handler,@NotNull final ServiceLimits limits) throws IOException, InterruptedException {
  return new Service(port,cluster,handler,limits);
}

Fixed version (ground truth):
public static Service register(final int port,@NotNull final String cluster,@NotNull final ServiceHandler handler,@NotNull final ServiceLimits limits) throws IOException, InterruptedException, InitializationException {
  return new Service(port,cluster,handler,limits);
}
Program: 86489
Project: 86489
Buggy source:
Service(final int port,@NotNull final String cluster,@NotNull final ServiceHandler handler,@Nullable final ServiceLimits limits) throws IOException, InterruptedException {
  connection=new Connection(port,cluster,handler,limits);
  try {
    handler.init(connection);
  }
 catch (  Exception e) {
    connection.close();
  }
}

Fixed version (ground truth):
Service(final int port,@NotNull final String cluster,@NotNull final ServiceHandler handler,@NotNull final ServiceLimits limits) throws IOException, InterruptedException, InitializationException {
  final ContextualLogger logger=new ContextualLogger(LoggerFactory.getLogger(Iris.class.getPackage().getName()),"String_Node_Str",String.valueOf(nextServId.incrementAndGet()));
  try {
    logger.loadContext();
    logger.info("String_Node_Str","String_Node_Str",String.valueOf(port),"String_Node_Str",cluster,"String_Node_Str",String.format("String_Node_Str",limits.broadcastThreads,limits.broadcastMemory),"String_Node_Str",String.format("String_Node_Str",limits.requestThreads,limits.requestMemory));
    connection=new Connection(port,cluster,handler,limits,logger);
    try {
      handler.init(connection);
      logger.info("String_Node_Str");
    }
 catch (    InitializationException e) {
      logger.warn("String_Node_Str","String_Node_Str",e.getMessage());
      connection.close();
      throw e;
    }
  }
 catch (  IOException|InterruptedException e) {
    logger.warn("String_Node_Str","String_Node_Str",e.getMessage());
    throw e;
  }
 finally {
    logger.unloadContext();
  }
}
Program: 86490
Project: 86490
Buggy source:
default void init(@NotNull final Connection connection){
}

Fixed version (ground truth):
default void init(@NotNull final Connection connection) throws InitializationException {
}
Program: 86491
Project: 86491
Buggy source:
public boolean schedule(Runnable task,int size,int timeout){
}

Fixed version (ground truth):
public boolean schedule(Runnable task,int size){
  if (!capacity.tryAcquire(size)) {
    return false;
  }
  workers.submit(() -> {
    capacity.release(size);
    task.run();
  }
);
  return true;
}