tomecho / defects4j

A Database of Existing Faults to Enable Controlled Testing Studies for Java
MIT License
0 stars 1 forks source link

Merging bug mining into master initialize-revisions.pl #1

Open tomecho opened 7 years ago

tomecho commented 7 years ago

Getting an error when I try running initialize revisions

tapeck@1x-nat-vl931-172-30-149-144:~/Documents/school/cs596/defects4j/work$ perl ../framework/bug-mining/initialize-revisions.pl -p Lang -w .
Invalid number of arguments! Use: create_project(project_id) at /Users/tapeck/Documents/school/cs596/defects4j/framework/core/Project.pm line 117.
tomecho commented 7 years ago

New core framework project scripts dont support temp dir image so we need to start support it #X

tomecho commented 7 years ago

I remapped the commit db from framework/core/lang to work/commit-db (work being the path supplied as command line arg to initialize-revisions.pl)

tomecho commented 7 years ago

what is vcs->_co_hook? edit: whatever it is, looks like the merge branch is not running it, that needs to be fixed edit2: actually it is being run, it looks like it copies the build.xml into the temp work_dir if it doesn't exist already, but not all revisions exist in the source of the copying location, that might be a problem.

tomecho commented 7 years ago

Created new patches on the fly using revised and buggy revision ids but it still has a problem applying a few of the patches

i manually flipped the buggy vs fixed on bug 2 (which was failing to apply occasionally) in commit db and it worked

actually, i flipped it again and it just worked. This is a weird error, that is really hard to fix since I cant reproduce it effectivly.

tomecho commented 7 years ago

looks like the diff for bug id 2 is created incorrectly but I dont know why. There must be something in the checkout_vid method that breaks the diff before i can apply it.

tomecho commented 7 years ago

patch does not apply error is fixed, just have to modify a few paths from script_dir to work_dir

tomecho commented 7 years ago

Project::checkout_vid depends on

rjust commented 6 years ago

I bypassed these issues by calling project->{_vcs}->checkout_vid, which does not depend on the existence of the meta data.

@tomecho, Can you please check whether my current implementation makes sense to you?