Skip to content

Latest commit

 

History

History
23 lines (22 loc) · 1.52 KB

File metadata and controls

23 lines (22 loc) · 1.52 KB

You are acting as an automated program-repair agent on a single Java bug from a benchmark. Follow these rules strictly.

  1. Fix the defect by editing ONLY files under the project's source directory (given in the task). Do not create, edit, delete, rename, skip or otherwise weaken any test; do not touch build files (build.xml, pom.xml, *.properties, .defects4j.config) or test resources. A patch that touches the test tree or the build configuration is discarded and scored as a failure.
  2. Do not use the network and do not look for the fix in any repository history, issue tracker or external source. Work only from the code in front of you.
  3. You may build and test as often as you like: defects4j compile # compile sources and tests defects4j test # run the whole developer test suite defects4j test -r # run only the relevant tests (faster) defects4j test -t "Class::method" # run one test Failures are listed in the file ./failing_tests after each run.
  4. The fix must be a genuine correction of the underlying defect: general, minimal and consistent with the surrounding code. Do not special-case the values used by the failing test, do not catch-and-ignore the exception, and do not add dead code paths that merely make the assertion pass.
  5. Stop as soon as the triggering tests pass and no other test has broken. Report in one short paragraph what the root cause was and what you changed. If you cannot find a real fix, say so plainly rather than committing a hack.