Граф коммитов

86 Коммитов

Автор SHA1 Сообщение Дата
Marco Castelluccio 4e39a619ed Consider remote DB as old if the remote version file returns any HTTP error 2019-07-27 02:05:11 +02:00
Marco Castelluccio 3747171716 Consider remote DB old if there is no version file yet 2019-07-27 02:05:11 +02:00
Marco Castelluccio 785aeca537 Support getting revisions before a given revision 2019-07-27 02:05:11 +02:00
Marco Castelluccio 73633e2e00 Make DB version handling saner to use
Fixing a problem where the retriever tasks would always write a version file
containing the version of the old DB.
2019-07-26 23:37:46 +02:00
Marco Castelluccio d54472f027 Don't raise an exception when a DB is not yet available
For example, the first time a task is created.
2019-07-23 02:14:22 +02:00
Anurag Aggarwal fbd411157c Add basic test case for the Uplift model (#696)
Fixes #437
2019-07-15 23:29:28 +02:00
Marco Castelluccio 09741b82df Remove tests for the old 'title' feature 2019-07-11 20:55:19 +02:00
Harshit chittora d5154c837d Use some bug features in the Backout model (#615)
Fixes #577.
2019-07-11 15:42:02 +02:00
Marco Castelluccio d08e062c68 Improve triggerSchema of the hooks and test it 2019-07-03 17:26:01 +02:00
Marco Castelluccio a94fe63d76 Test generated hooks are json-e renderable 2019-07-02 21:04:23 +02:00
Yun Seob Lee 259088cce8 Add basic test for the Assignee model (#621) 2019-07-02 20:52:08 +02:00
Marco Castelluccio 8961e22059 When the pushdate is not available because the commit is local only, use 'now' as the pushdate 2019-07-02 12:21:35 +02:00
x249wang 30d19efb5b Remove fallback on downloading xz files (#644) 2019-07-01 11:58:20 +02:00
Yun Seob Lee f836f25291 Add basic test for DevDocNeeded model (#661)
Fixes #435
2019-07-01 11:46:52 +02:00
Marco Castelluccio b969a4576c Fallback on xz URL for Last-Modified if the zst URL is not available 2019-06-26 21:46:40 +02:00
Marco Castelluccio a05096541d Don't try to extract files that are not compressed
Or we will fail downloading the DB version.
Also add a test for download_version and is_old_version.
2019-06-26 19:59:30 +02:00
Marco Castelluccio bcf405c747 Ensure pipeline yaml files are valid YAML and can be rendered with JSON-e
Part of #613
2019-06-26 18:35:46 +02:00
cklyyung 4124e0a990 Add tests for repository.download_component_mapping (#623) 2019-06-25 14:23:09 +02:00
x249wang ab28e8ace2 Use zstandard instead of xz (#524)
Fixes #461.
2019-06-24 13:16:44 +02:00
Yun Seob Lee af569c9c8e Add basic test for the Regression model (#618) 2019-06-22 12:44:31 -07:00
Yun Seob Lee 511a53a1de Add basic test for the backout model (#606) 2019-06-21 09:28:36 -07:00
cklyyung c9017df9ee Add basic test for defect model (#607) 2019-06-21 08:20:56 -07:00
Marco Castelluccio bc066eb3e6 Stop using subprocess in test_run.py, but import run.py and test its functions 2019-06-10 11:06:01 +02:00
Marco Castelluccio 23d76d3610 Collect coverage during the run.py test 2019-06-08 21:42:20 +02:00
Sladyn 860bb69c10 Add a basic test for the StepsToReproduce model (#503) 2019-06-07 11:11:39 +02:00
Marco ee935d6e5b
Download previous commits DB and experiences, and only mine data for new commits landed since then (#546)
* Download previous commits DB and experiences, and only mine data for new commits landed since then

Fixes #537

* Simplify db methods

* Add an option to return mined commits
2019-06-06 18:55:17 +02:00
Marco Castelluccio 47eb2da7ec Don't overwrite the first_pushdate value
Follow up to bea28a17f6
2019-06-05 01:07:12 +02:00
Marco Castelluccio bea28a17f6 Get first pushdate from hg log on following runs of the repository mining script
Otherwise we'd use the pushdate of the first new commit as the first pushdate.
2019-06-04 12:52:08 +02:00
Marco Castelluccio 36d7d4449e Store first_commit_time dict too in the experiences file
Otherwise on following runs of calculate_experiences we'd have wrong seniority.
2019-06-04 12:51:29 +02:00
Marco d8b84ca798
Support retrieving commits in steps (#536)
* Support retrieving commits in steps

* Store component mapping ETag to actually avoid downloading it again when not needed

* Store a version file alongside the DBs

* Export the commits DB version file and the experiences values as artifacts of the commit-retriever task
2019-06-03 19:29:08 +02:00
Marco Castelluccio 32f024b9e3 Add a rev_start parameter to repository.get_revs and test it 2019-06-03 16:02:01 +02:00
Marco Castelluccio e3b4d3fcc8 Add a test for repository.download_commits
Fixes #379
2019-06-03 15:52:22 +02:00
Ibraheem Moosa 2c41533c52 Clean the test data for cleanup functions (#530) 2019-06-03 14:37:46 +02:00
Marco Castelluccio ad98a3f911 Add tests for repository.hg_log
Fixes #385
2019-06-03 10:22:08 +02:00
Marco Castelluccio 0e08d04903 Fix subclass detection in trainer script 2019-05-30 18:55:22 +02:00
Marco Castelluccio e729d68d82 Assert get_all_bug_ids returns only numbers 2019-05-30 16:15:54 +02:00
Marco Castelluccio 51e7297a89 Test type of component and backout models 2019-05-30 13:25:26 +02:00
Marco 62b348d46c
Don't skip commits when calculating experiences (#510)
* Skip commits after calculating experience

Fixes #502

* Skip commits that have 'ignore-this-changeset' in their description

Fixes #496

* Don't increase experience for commits to ignore

* Test skipping a commit when calculating experiences

* Add test for repository.get_commits_to_ignore

* Add implementations of __eq__ and __hash__ in the Commit class
2019-05-29 11:24:11 +02:00
x249wang a5c584afa2 Add basic tests for the BugType model (#513) 2019-05-29 10:39:33 +02:00
Marco 837788428a
Calculate experiences of backed-out commits too (#497)
* Calculate experience for backed-out commits too

Fixes #373

* Add a backed-out commit to the list to make sure it doesn't affect normal experiences

* Add backout experience features
2019-05-28 12:59:55 +02:00
Marco 3f731dad1b
Optimize experience calculation by having lists specific to items instead of carrying over the entire history all the time (#488)
* Stop getting a subset of revs

* Instead of carrying over all history day-by-day, use a deque with experience specific to a single item
2019-05-24 15:33:57 +02:00
Ayush Shridhar ec25e5126b Add tests for seniority calculation (#480) 2019-05-22 00:53:11 +02:00
Marco 1e18cd3fac
Store experiences directly in the commit object (#477)
* Store experiences directly in the commit object

This way we can avoid the huge dict of dicts of dicts mapping commit hashes to experiences

* Use tqdm to see progress during seniority calculation

* Make 'first_commit_time' a simple dict

* Store seniority directly in the commit object
2019-05-21 16:20:46 +02:00
Marco Castelluccio 463c174508 Assert the list of bug IDs returned by get_all_bug_ids is longer than 0 2019-05-21 01:27:45 +02:00
Marco 72dab1a6d8
Gather more features about experiences (#467)
* Refactor things to avoid multiple sums and set updates

* Store max and min values too for experiences

* Store touched files and directories too as part of the commit data

* Remove useless default value for files_modified_num

* Use f-string instead of string concatenation for feature names

* Add more features about experiences (average, maximum, minimum, number of elements)

Fixes #370
2019-05-20 13:14:18 +02:00
Marco 4e26a1e64f
Make bug snapshotting code fail silently when really necessary (#457)
* Remove useless 'pass'

* Remove all_inconsistencies and verbose options

* Add a 'platform' field mapping

* Don't assert during training or during evaluation

These kinds of assertions can be very frequent unfortunately, so we only enable them when needed.
That is:
1) During CI tests;
2) During rollback test, after downloading a new set of bugs (which we want to make sure is "clean enough").

Fixes #450

* Move all inconsistencies checks into separate functions, to make rollback code cleaner

* Fix assertion/log message
2019-05-17 20:06:57 +02:00
Boris Feld 0a5e37439d Add a central place where the models are defined (#398)
* Add a central place where the models are defined

Also add some helpers to load a model.

* Add missing tensorflow dependency in extra-nn-requirements.txt
2019-05-16 15:34:38 +02:00
Marco Castelluccio 3c91af9c60 Exclude previous commits since the beginning
Better implementation of 837169ebce
2019-05-16 01:51:28 +02:00
Ayush Shridhar add9a937b3 Multilabel classifier for detecting type of bug (#395) 2019-05-14 12:17:53 +02:00
Marco ed992d57ec
Initial tests for repository module (#377)
* Test repository.get_revs function

* Test repository.get_directories function

* Split _hg_log function called by ProcessPoolExecutor in two to make it more easily testable

* Add logging when downloading file->component mapping

* Move the experience calculation code in a separate function

* Don't break experiences when there are days without commits

* Add tests for repository.calculate_experiences

Fixes #382

*  When a commit changes multiple files in the same component, don't overcount the experience

The commit itself was being considered as a previous commit touching the same components
2019-05-14 11:30:56 +02:00