A Mining Approach towards Automating Regression Dataset Construction from Code Evolution History. This project is powerd by SE lab in Fudan University
We also provide UI-free tools to help users replay test results for each regression bug. Get that support in the regs4J project.
Env requirements for RegMiner:
-
OS: MacOS/Ubuntu/CentOS
-
JDK: 11
-
Python: 3.0+
Attention! We have discovered that RegMiner does not run well on Windows OS, and currently, we don't plan to fix it.
Env requirements for mining projects:
- JDK LTS: 1.7,1.8,11,17
- Maven or Gradle
- Others*: The specific environment required by a particular project. For example, MongoDB may be necessary for a project related to MongoDB middleware.
Easy Start:
Steps are as follows:
(1) Prepare the data.
-
Create a workspace for Miner.
mkdir miner_space
-
Create a directory for maintaining the source code of the mined project.
cd miner_space
mkdir meta_projects
- Prepare source code of the mined project. In the example, we use
uniVocity/univocity-parsers
.
cd meta_projects
git clone https://github.com/uniVocity/univocity-parsers.git
(2) Generate the configuration.
- Modify the configuration related to the database in
scripts/gen_config.py
.
sql_enable=0
This modification will disable the MySQL functionality of RegMiner. We currently do not provide the SQL table structure. If you need it, please contact Xuezhi.
- Generate the configuration file.
cd /xxx/xxxx/RegMiner/scripts
rm env.properties
python gen_config.py
mv env.properties ../
These commands will generate the necessary configuration for running Regminer. The script will automatically detect the JDK installed on the system.
- Load RegMiner Project to IDEA.
- Config debug params.
-ws /xxx/xxx/miner_space/ -pj univocity-parsers -cfg env.properties -t bfc
-t bfc
means just mine bfc; -t bfc&bic
means search for regressions.
- Run RegMiner in
miner/src/main/java/org/regminer/miner/start/MinerCli.java
, you can find progress info inlogs/app.log
Automated mining of target project sets.
- Build the JAR package for RegMiner and place it in the
scripts
directory, and movescripts
directory tominer_space
. - Run
python gen_config.py
underscripts
directory. - Prepare a list of project names in file
projects.in
underscripts
directory, with one project per line. - Clone the source code of these projects with
.git
files intominer_space/meta_projects
. - Run the
run_multi_projects.py
underscripts
directory to mine the projects in the list.
You can see the comments in the scripts for more details.
-
Xuezhi Song, Yun Lin*, Siang Hwee Ng, Yijian Wu, Xin Peng, Jin Song Dong and Hong Mei. RegMiner: Towards Constructing a Large Regression Dataset from Code Evolution History [⚡ CCF Prototype Competition Award (1st Prize)]
-
Xuezhi Song, Yun Lin*, Yijian Wu, Yifan Zhang, Xin Peng, Jin Song Dong, and Hong Mei. RegMiner: Mining Replicable Regression Dataset from Code Repositories
-
Xuezhi Song, Yijian Wu*, Junming Cao, Bihuan Chen, Yun Lin, Zhengjie Lu, Dingji Wang, Xin Peng. BugMiner: Automating Precise Bug Dataset Construction by Code Evolution History Mining
We express our great thanks for JetBrains support on RegMiner.