All Projects → program-repair → defects4j-dissection

program-repair / defects4j-dissection

Licence: MIT license
Defects4J Dissection presents data to help researchers and practitioners to better understand the Defects4J bug dataset

Programming Languages

python
139335 projects - #7 most used programming language
javascript
184084 projects - #8 most used programming language

Projects that are alternatives of or similar to defects4j-dissection

clear-water
Forecasting elevated levels of E. coli at Chicago beaches to provide proper warning to beach-goers.
Stars: ✭ 54 (+28.57%)
Mutual labels:  open-science
simon-frontend
💹 SIMON is powerful, flexible, open-source and easy to use machine learning knowledge discovery platform 💻
Stars: ✭ 114 (+171.43%)
Mutual labels:  open-science
datascience
Keeping track of activities around research data
Stars: ✭ 29 (-30.95%)
Mutual labels:  open-science
Luminescence
Development of the R package 'Luminescence'
Stars: ✭ 13 (-69.05%)
Mutual labels:  open-science
inferring-hidden-structure-retinal-circuits
Data and example scripts used in the paper `Inferring hidden structure in multilayered neural circuits`
Stars: ✭ 13 (-69.05%)
Mutual labels:  open-science
bioportal web ui
A Rails application for biological ontologies
Stars: ✭ 20 (-52.38%)
Mutual labels:  open-science
Open Computational Neuroscience Resources
A publicly-editable collection of open computational neuroscience resources
Stars: ✭ 234 (+457.14%)
Mutual labels:  open-science
whyqd
data wrangling simplicity, complete audit transparency, and at speed
Stars: ✭ 16 (-61.9%)
Mutual labels:  open-science
open-heroes
Some people that facilitate science, one way or the other
Stars: ✭ 37 (-11.9%)
Mutual labels:  open-science
neurotic
Curate, visualize, annotate, and share your behavioral ephys data using Python
Stars: ✭ 24 (-42.86%)
Mutual labels:  open-science
catlearn
Formal Psychological Models of Categorization and Learning
Stars: ✭ 21 (-50%)
Mutual labels:  open-science
wowchemy-hugo-themes
🔥 Hugo website builder, Hugo themes & Hugo CMS. No code, easily build with blocks! 创建在线课程,学术简历或初创网站。#OpenScience
Stars: ✭ 6,891 (+16307.14%)
Mutual labels:  open-science
pem-dataset1
Proton Exchange Membrane (PEM) Fuel Cell Dataset
Stars: ✭ 48 (+14.29%)
Mutual labels:  open-science
git-rdm
A research data management plugin for the Git version control system.
Stars: ✭ 34 (-19.05%)
Mutual labels:  open-science
ck-mlops
A collection of portable workflows, automation recipes and components for MLOps in a unified CK format. Note that this repository is outdated - please check the 2nd generation of the CK workflow automation meta-framework with portable MLOps and DevOps components here:
Stars: ✭ 15 (-64.29%)
Mutual labels:  open-science
Open Science 101
Open_Science_101
Stars: ✭ 24 (-42.86%)
Mutual labels:  open-science
COSN webinar
Tutorial talks at the Chinese Open Science Webinar series
Stars: ✭ 26 (-38.1%)
Mutual labels:  open-science
mozilla-sprint-2018
DEPRECATED & Materials Moved: This sprint was to focus on brainstorming for the Joint Roadmap for Open Science Tools.
Stars: ✭ 24 (-42.86%)
Mutual labels:  open-science
events
Materials related to events I might attend, and to talks I am giving
Stars: ✭ 22 (-47.62%)
Mutual labels:  open-science
open-solution-ship-detection
Open solution to the Airbus Ship Detection Challenge
Stars: ✭ 54 (+28.57%)
Mutual labels:  open-science

Defects4J Dissection

Defects4J Dissection presents data to help researchers and practitioners to better understand the Defects4J bug dataset. It is the open-science appendix of "Dissection of a Bug Dataset: Anatomy of 395 Patches from Defects4J".

@inproceedings{defects4J-dissection,
    title = {{Dissection of a Bug Dataset: Anatomy of 395 Patches from Defects4J}},
    author = {Sobreira, Victor and Durieux, Thomas and Madeiral, Fernanda and Monperrus, Martin and Maia, Marcelo A.},
    booktitle = {Proceedings of SANER},
    year = {2018},
    doi = {10.1109/SANER.2018.8330203}
}

Main files:

Contributions

  • Simon Heiden @heidensi for the manually extraction of the changed lines.

defects4j-bugs.json format

[
  {
    "bugId": 18,
    "changedFiles": {
      "org/jfree/data/DefaultKeyedValues.java": {
        "changes": [ // contains lines that are changed by the patch 
          [
            335
          ]
        ],
        "deletes": [ // contains lines that are deleted by the patch 
          [
            318
          ],
          [
            320
          ]
        ]
      },
      "org/jfree/data/DefaultKeyedValues2D.java": {
        "inserts": [ // contains lines *before* which code is inserted by the patch 
          [
            455, // multiple lines in an inner array represent multiple possible locations to insert the code
            456
          ],
          [
            458
          ],
          [
            459
          ]
        ]
      } // caution: '-1' as a line number represents the insertion of a method or variable declaration that can not be tied to a specific location
    },
    "diff": "--- a/source/org/jfree/data/DefaultKeyedValues.java\n+++ b/source/org/jfree/data/DefaultKeyedValues.java\n@@ -315,30 +315,29 @@ private void rebuildIndex () {\n     public void removeValue(int index) {\n         this.keys.remove(index);\n         this.values.remove(index);\n-        if (index < this.keys.size()) {\n         rebuildIndex();\n-        }\n     }\n \n     /**\n      * Removes a value from the collection.\n      *\n      * @param key  the item key (<code>null</code> not permitted).\n      * \n      * @throws IllegalArgumentException if <code>key</code> is \n      *     <code>null</code>.\n      * @throws UnknownKeyException if <code>key</code> is not recognised.\n      */\n     public void removeValue(Comparable key) {\n         int index = getIndex(key);\n         if (index < 0) {\n-\t\t\treturn;\n+            throw new UnknownKeyException(\"The key (\" + key \n+                    + \") is not recognised.\");\n         }\n         removeValue(index);\n     }\n     \n     /**\n      * Clears all values from the collection.\n      * \n      * @since 1.0.2\n      */\n--- a/source/org/jfree/data/DefaultKeyedValues2D.java\n+++ b/source/org/jfree/data/DefaultKeyedValues2D.java\n@@ -454,12 +454,21 @@ public void removeColumn(int columnIndex) {\n     public void removeColumn(Comparable columnKey) {\r\n+    \tif (columnKey == null) {\r\n+    \t\tthrow new IllegalArgumentException(\"Null 'columnKey' argument.\");\r\n+    \t}\r\n+    \tif (!this.columnKeys.contains(columnKey)) {\r\n+    \t\tthrow new UnknownKeyException(\"Unknown key: \" + columnKey);\r\n+    \t}\r\n         Iterator iterator = this.rows.iterator();\r\n         while (iterator.hasNext()) {\r\n             DefaultKeyedValues rowData = (DefaultKeyedValues) iterator.next();\r\n+            int index = rowData.getIndex(columnKey);\r\n+            if (index >= 0) {\r\n                 rowData.removeValue(columnKey);\r\n+            }\r\n         }\r\n         this.columnKeys.remove(columnKey);\r\n     }\r\n \r\n     /**\r\n      * Clears all the data and associated keys.\r\n      */\r\n",
    "failingTests": [
      {
        "className": " org.jfree.data.category.junit.DefaultCategoryDatasetTests",
        "error": "java.lang.IndexOutOfBoundsException",
        "message": "Index: 0, Size: 0",
        "methodName": "testBug1835955"
      },
      {
        "className": " org.jfree.data.junit.DefaultKeyedValues2DTests",
        "error": "java.lang.IndexOutOfBoundsException",
        "message": "Index: 0, Size: 0",
        "methodName": "testRemoveColumnByKey"
      },
      {
        "className": " org.jfree.data.junit.DefaultKeyedValuesTests",
        "error": "junit.framework.AssertionFailedError",
        "message": "",
        "methodName": "testRemoveValue"
      },
      {
        "className": " org.jfree.data.junit.DefaultKeyedValuesTests",
        "error": "junit.framework.AssertionFailedError",
        "message": "expected:<-1> but was:<0>",
        "methodName": "testGetIndex2"
      }
    ],
    "metrics": {
      "chunks": 6,
      "classes": 2,
      "files": 2,
      "linesAdd": 10,
      "linesMod": 1,
      "linesRem": 2,
      "methods": 3,
      "sizeInLines": 13,
      "spreadAllLines": 19,
      "spreadCodeOnly": 9
    },
    "observations": "Replaces return point by throw exception.",
    "program": "jfreechart",
    "project": "Chart",
    "repairActions": [
      "assignAdd",
      "condBranIfAdd",
      "condBranRem",
      "exThrowsAdd",
      "mcAdd",
      "mcRem",
      "objInstAdd",
      "retRem",
      "varAdd"
    ],
    "repairPatterns": [
      "condBlockExcAdd",
      "missNullCheckP",
      "unwrapIfElse",
      "wrapsIf"
    ],
    "repairTools": [
      "rtDeepRepair",
      "rtGPFL"
    ],
    "revisionId": "621"
  }
]

defects4j-bugs.json acronyms

Acronym Description
mdAdd Method definition addition
mdRem Method definition removal
mdRen Method definition renaming
mdParAdd Parameter addition in method definition
mdParRem Parameter removal from method definition
mdRetTyChange Method return type modification
mdParTyChange Parameter type modification in method definition
mdModChange Method modifier change
mdOverride Method overriding addition or removal
mcAdd Method call addition
mcRem Method call removal
mcRepl Method call replacement
mcParSwap Method call parameter value swapping
mcParAdd Method call parameter addition
mcParRem Method call parameter removal
mcParValChange Method call parameter value modification
mcMove Method call moving
objInstAdd Object instantiation addition
objInstRem Object instantiation removal
objInstMod Object instantiation modification
varAdd Variable addition
varRem Variable removal
varReplVar Variable replacement by another variable
exTryCatchAdd try-catch addition
exTryCatchRem try-catch removal
exThrowsAdd throw addition
exThrowsRem throw removal
condExpRed Conditional expression reduction
condExpExpand Conditional expression expansion
condExpMod Conditional expression modification
condBranIfAdd Conditional (if) branch addition
condBranIfElseAdd Conditional (if-else) branches addition
condBranElseAdd Conditional (else) branch addition
condBranCaseAdd Conditional (case in switch) branch addition
condBranRem Conditional (if or else) branch removal
assignAdd Assignment addition
assignRem Assignment removal
assignExpChange Assignment expression modification
loopAdd Loop addition
loopRem Loop removal
loopCondChange Loop conditional expression modification
loopInitChange Loop initialization field modification
varTyChange Variable type change
varModChange Variable modifier change
varReplMc Variable replacement by method call
tyAdd Type addition
tyImpInterf Type implemented interface modification
retExpChange Return expression modification
retBranchAdd Return statement addition
retRem Return statement removal
wrapsIf Wraps-with if statement
wrapsIfElse Wraps-with if-else statement
wrapsElse Wraps-with else statement
wrapsTryCatch Wraps-with try-catch block
wrapsMethod Wraps-with method call
wrapsLoop Wraps-with loop
unwrapIfElse Unwraps-from if-else statement
unwrapMethod Unwraps-from method call
unwrapTryCatch Unwraps-from try-catch block
condBlockExcAdd Conditional block addition with exception throwing
condBlockRetAdd Conditional block addition with return statement
condBlockOthersAdd Conditional block addition
condBlockRem Conditional block removal
missNullCheckP Missing null check addition
missNullCheckN Missing non-null check addition
expLogicExpand Logic expression expansion
expLogicReduce Logic expression reduction
expLogicMod Logic expression modification
expArithMod Arithmetic expression modification
codeMove Code Moving
wrongVarRef Wrong Variable Reference
wrongMethodRef Wrong Method Reference
singleLine Single Line
notClassified Not classified
copyPaste Copy/Paste
constChange Constant Change
rtAcs Patched by ACS
rtCardumen Patched by Cardumen
rtDeepRepair Patched by DeepRepair
rtDynaMoth Patched by DynaMoth
rtElixir Patched by Elixir
rtGPFL Patched by GPFL
rtHDRepair Patched by HDRepair
rtGenProg Patched by jGenProg
rtKali Patched by jKali
rtNopol Patched by Nopol
rtssFix Patched by ssFix

Automatic repair information sources:

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].