Skip to content

Commit

Permalink
Merge pull request #244 from MaLoefUDS/dev
Browse files Browse the repository at this point in the history
Introduce issue-based artifact-network creation, new tests and fix current tests + minor bug fixes

Reviewed-by: Thomas Bock <bockthom@cs.uni-saarland.de>
Reviewed-by: Christian Hechtl <hechtl@cs.uni-saarland.de>
  • Loading branch information
bockthom authored Dec 20, 2023
2 parents 8b53d6c + 7f78966 commit 5febbda
Show file tree
Hide file tree
Showing 19 changed files with 1,041 additions and 610 deletions.
21 changes: 21 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,27 @@

# coronet – Changelog

## unversioned

### Added

- Add issue-based artifact-networks (PR #244, 98a93ee721a293410623aafe46890cfba9d81e72, 771bcc8d961d419b53a1e891e9dc536371f1143b)
- Add a new `split.data.by.bins` function (not to be confused with a previously existing function that had the same name and was renamed in this context), which splits data based on given activity-based bins (PR #244, ece569ceaf557bb38cd0cfad437b69b30fe8a698, ed5feb214a123b605c9513262f187cfd72b9e1f4)

### Changed/Improved

- Enhance testing data by adding `add_link` and `referenced_by` issue events which connect issues to form edges in issue-based artifact-networks (PR #244, 9f840c040d552e8639aa82c3dd537c189679b348, ea4fe8d3c84f948af6147cf0137e80181ebb7a1e)
- Add input validation for the `bins` parameter in `split.data.time.based` and `split.data.by.bins` (PR #244, ed0a5302ea8c8934d7200b95be7ac1446305af07, 5e5ecbac44d07927b953ae9d4330a616f8224ba7)
- Rename `split.data.by.bins` into `split.dataframe.by.bins` as this it what it does (PR #244, ed5feb214a123b605c9513262f187cfd72b9e1f4)

### Fixed

- Reformat `event.info.1` column of issue data according to the <issue-%source-%id> format, if the content of the `event.info.1` field references another issue (PR #244, 62ff9d0f31adbefb3381936237dc4ab984e33acb)
- Fix an issue in activity-based splitting where elements close to the border of bins might be assigned to the wrong bin. The issue was caused by the usage of `split.data.time.based` inside `split.data.activity.based` to split data into the previously derived bins, when elements close to bin borders share the same timestamps. It is fixed by replacing `split.data.time.based` by `split.data.by.bins` (PR #244, ece569ceaf557bb38cd0cfad437b69b30fe8a698)
- Remove the last range when using a sliding-window approach and the last range's elements are fully contained in the second last range (PR #244, 48ef4fa685adf6e5d85281e5b90a8ed8f6aeb197)
- Rename vertex attribute `IssueEvent` to `Issue` in multi-networks, to be consistent with bipartite-networks (PR #244, 26d7b7e9fd6d33d1c0a8a08f19c5c2e30346a3d9)


## 4.3

### Added
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"add_link";"Karl";"karl@example.org";"2016-08-07 15:37:02";"930af63a030fb92e48eddff01f53284c3eeba80e";"""commit"""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"referenced";"Karl";"karl@example.org";"2016-08-31 16:45:09";"";""""""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"referenced";"Thomas";"thomas@example.org";"2016-10-05 16:45:09";"";""""""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"add_link";"Karl";"karl@example.org";"2016-08-07 15:37:02";"6";"""issue"""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"add_link";"Thomas";"thomas@example.org";"2016-08-07 15:30:00";"2";"""issue"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"mentioned";"udo";"udo@example.org";"2016-07-12 15:30:02";"Thomas";"""thomas@example.org"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"subscribed";"udo";"udo@example.org";"2016-07-12 15:30:02";"Thomas";"""thomas@example.org"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"commented";"Thomas";"thomas@example.org";"2016-07-12 16:03:59";"open";"[]"
Expand All @@ -15,6 +17,7 @@
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"subscribed";"Björn";"bjoern@example.org";"2016-12-07 15:30:02";"udo";"""udo@example.org"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"labeled";"Olaf";"olaf@example.org";"2017-05-23 12:31:34";"decided";""""""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"commented";"Björn";"bjoern@example.org";"2017-05-23 12:32:39";"open";"[]"
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"referenced_by";"Karl";"karl@example.org";"2016-08-07 15:37:02";"3";"""issue"""
"1";"Example pull request 1";"[""pull request""]";"reopened";"[]";"2016-07-14 13:37:00";"";"[]";"created";"Thomas";"thomas@example.org";"2016-07-12 15:59:25";"open";"[]"
"1";"Example pull request 1";"[""pull request""]";"reopened";"[]";"2016-07-14 13:37:00";"";"[]";"commented";"Thomas";"thomas@example.org";"2016-07-12 15:59:25";"open";"[]"
"1";"Example pull request 1";"[""pull request""]";"reopened";"[]";"2016-07-14 13:37:00";"";"[]";"state_updated";"Thomas";"thomas@example.org";"2016-07-12 15:59:59";"closed";"""open"""
Expand All @@ -25,6 +28,7 @@
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"commented";"Björn";"bjoern@example.org";"2016-07-12 14:59:25";"open";"[]"
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"merged";"Olaf";"olaf@example.org";"2016-07-12 16:04:59";"";""""""
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"state_updated";"Olaf";"olaf@example.org";"2016-07-12 16:04:59";"closed";"""open"""
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"referenced_by";"Thomas";"thomas@example.org";"2016-08-07 15:30:00";"3";"""issue"""
"4";"Example pull request 4";"[""pull request"", ""enhancement""]";"open";"[]";"2016-07-12 16:02:02";"";"[]";"commit_added";"Björn";"bjoern@example.org";"2016-07-12 15:58:59";"72c8dd25d3dd6d18f46e2b26a5f5b1e2e8dc28d0";""""""
"4";"Example pull request 4";"[""pull request"", ""enhancement""]";"open";"[]";"2016-07-12 16:02:02";"";"[]";"created";"Olaf";"olaf@example.org";"2016-07-12 16:02:02";"open";"[]"
"4";"Example pull request 4";"[""pull request"", ""enhancement""]";"open";"[]";"2016-07-12 16:02:02";"";"[]";"commented";"Olaf";"olaf@example.org";"2016-07-12 16:02:02";"open";"[]"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"commented";"Olaf";"olaf@example.org";"2013-05-25 06:22:23";"open";"[""unresolved""]"
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"commented";"Olaf";"olaf@example.org";"2013-06-01 06:50:26";"open";"[""unresolved""]"
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"resolution_updated";"Björn";"bjoern@example.org";"2013-06-01 06:53:06";"fixed";"""unresolved"""
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"referenced_by";"Thomas";"thomas@example.org";"2017-05-21 12:00:00";"ZEPPELIN-332";"""issue"""
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"add_link";"Thomas";"thomas@example.org";"2017-05-21 12:00:00";"ZEPPELIN-328";"""issue"""
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"created";"Björn";"bjoern@example.org";"2016-07-12 16:01:30";"open";"[""unresolved""]"
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"commented";"Björn";"bjoern@example.org";"2016-07-12 16:02:30";"open";"[""unresolved""]"
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"commented";"Björn";"bjoern@example.org";"2016-07-15 19:55:39";"open";"[""unresolved""]"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"add_link";"Karl";"karl@example.org";"2016-08-07 15:37:02";"930af63a030fb92e48eddff01f53284c3eeba80e";"""commit"""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"referenced";"Karl";"karl@example.org";"2016-08-31 16:45:09";"";""""""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"referenced";"Thomas";"thomas@example.org";"2016-10-05 16:45:09";"";""""""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"add_link";"Karl";"karl@example.org";"2016-08-07 15:37:02";"6";"""issue"""
3;"Error in construct.networks.from.list for openssl function networks";"[""issue"", ""bug""]";"closed";"[]";"2016-07-12 15:59:25";"2016-07-12 16:06:30";"[]";"add_link";"Thomas";"thomas@example.org";"2016-08-07 15:30:00";"2";"""issue"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"mentioned";"udo";"udo@example.org";"2016-07-12 15:30:02";"Thomas";"""thomas@example.org"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"subscribed";"udo";"udo@example.org";"2016-07-12 15:30:02";"Thomas";"""thomas@example.org"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"commented";"Thomas";"thomas@example.org";"2016-07-12 16:03:59";"open";"[]"
Expand All @@ -15,6 +17,7 @@
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"subscribed";"Björn";"bjoern@example.org";"2016-12-07 15:30:02";"udo";"""udo@example.org"""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"labeled";"Olaf";"olaf@example.org";"2017-05-23 12:31:34";"decided";""""""
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"commented";"Björn";"bjoern@example.org";"2017-05-23 12:32:39";"open";"[]"
6;"Distinguish directedness of networks and edge-construction algorithm";"[""issue"", ""bug"", ""enhancement""]";"open";"[]";"2016-07-12 14:30:13";"";"[]";"referenced_by";"Karl";"karl@example.org";"2016-08-07 15:37:02";"3";"""issue"""
"1";"Example pull request 1";"[""pull request""]";"reopened";"[]";"2016-07-14 13:37:00";"";"[]";"created";"Thomas";"thomas@example.org";"2016-07-12 15:59:25";"open";"[]"
"1";"Example pull request 1";"[""pull request""]";"reopened";"[]";"2016-07-14 13:37:00";"";"[]";"commented";"Thomas";"thomas@example.org";"2016-07-12 15:59:25";"open";"[]"
"1";"Example pull request 1";"[""pull request""]";"reopened";"[]";"2016-07-14 13:37:00";"";"[]";"state_updated";"Thomas";"thomas@example.org";"2016-07-12 15:59:59";"closed";"""open"""
Expand All @@ -25,6 +28,7 @@
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"commented";"Björn";"bjoern@example.org";"2016-07-12 14:59:25";"open";"[]"
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"merged";"Olaf";"olaf@example.org";"2016-07-12 16:04:59";"";""""""
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"state_updated";"Olaf";"olaf@example.org";"2016-07-12 16:04:59";"closed";"""open"""
"2";"Example pull request 2";"[""pull request""]";"closed";"[]";"2016-07-12 14:59:25";"2016-07-12 16:04:59";"[]";"referenced_by";"Thomas";"thomas@example.org";"2016-08-07 15:30:00";"3";"""issue"""
"4";"Example pull request 4";"[""pull request"", ""enhancement""]";"open";"[]";"2016-07-12 16:02:02";"";"[]";"commit_added";"Björn";"bjoern@example.org";"2016-07-12 15:58:59";"72c8dd25d3dd6d18f46e2b26a5f5b1e2e8dc28d0";""""""
"4";"Example pull request 4";"[""pull request"", ""enhancement""]";"open";"[]";"2016-07-12 16:02:02";"";"[]";"created";"Olaf";"olaf@example.org";"2016-07-12 16:02:02";"open";"[]"
"4";"Example pull request 4";"[""pull request"", ""enhancement""]";"open";"[]";"2016-07-12 16:02:02";"";"[]";"commented";"Olaf";"olaf@example.org";"2016-07-12 16:02:02";"open";"[]"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"commented";"Olaf";"olaf@example.org";"2013-05-25 06:22:23";"open";"[""unresolved""]"
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"commented";"Olaf";"olaf@example.org";"2013-06-01 06:50:26";"open";"[""unresolved""]"
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"resolution_updated";"Björn";"bjoern@example.org";"2013-06-01 06:53:06";"fixed";"""unresolved"""
"ZEPPELIN-328";"[ZEPPELIN-328] Interpreter page should clarify the % magic syntax for interpreter group.name";"[""issue"", ""bug""]";"closed";"[""fixed""]";"2013-04-21 23:52:09";"2013-05-25 20:02:08";"[""GUI"", ""Interpreters""]";"referenced_by";"Thomas";"thomas@example.org";"2017-05-21 12:00:00";"ZEPPELIN-332";"""issue"""
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"add_link";"Thomas";"thomas@example.org";"2017-05-21 12:00:00";"ZEPPELIN-328";"""issue"""
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"created";"Björn";"bjoern@example.org";"2016-07-12 16:01:30";"open";"[""unresolved""]"
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"commented";"Björn";"bjoern@example.org";"2016-07-12 16:02:30";"open";"[""unresolved""]"
"ZEPPELIN-332";"[ZEPPELIN-332] CNFE when running SQL query against Cassandra temp table";"[""issue"", ""bug""]";"open";"[""unresolved""]";"2016-07-12 16:01:30";"";"[""Interpreters""]";"commented";"Björn";"bjoern@example.org";"2016-07-15 19:55:39";"open";"[""unresolved""]"
Expand Down
5 changes: 3 additions & 2 deletions tests/test-core-peripheral.R
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
## Copyright 2022 by Thomas Bock <bockthom@cs.uni-saarland.de>
## Copyright 2019 by Christian Hechtl <hechtl@fim.uni-passau.de>
## Copyright 2021 by Christian Hechtl <hechtl@cs.uni-saarland.de>
## Copyright 2023 by Maximilian Löffler <s8maloef@stud.uni-saarland.de>
## All Rights Reserved.


Expand Down Expand Up @@ -171,8 +172,8 @@ test_that("Issue-count classification" , {
result = get.author.class.issue.count(proj.data, issue.type = "all")

## Assert
expected.core = data.frame(author.name = c("Björn", "Olaf", "Thomas"), issue.count = c(6, 6, 4))
expected.peripheral = data.frame(author.name = c("Karl", "Max", "udo"), issue.count = c(1, 1, 1))
expected.core = data.frame(author.name = c("Björn", "Olaf", "Thomas"), issue.count = c(6, 6, 6))
expected.peripheral = data.frame(author.name = c("Karl", "Max", "udo"), issue.count = c(2, 1, 1))
expected = list(core = expected.core, peripheral = expected.peripheral)

row.names(result[["core"]]) = NULL
Expand Down
5 changes: 3 additions & 2 deletions tests/test-data.R
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
## Copyright 2021 by Johannes Hostert <s8johost@stud.uni-saarland.de>
## Copyright 2021 by Mirabdulla Yusifli <s8miyusi@stud.uni-saarland.de>
## Copyright 2022 by Jonathan Baumann <joba00002@stud.uni-saarland.de>
## Copyright 2023 by Maximilian Löffler <s8maloef@stud.uni-saarland.de>
## All Rights Reserved.


Expand Down Expand Up @@ -402,8 +403,8 @@ test_that("Filter bots from issue data", {
filtered.issues = proj.data$get.issues()

expect_true(all(filtered.issues[["author.name"]] != "Thomas"))
## there are now 41 issue events remaining, since 6 issue events have been removed during filtering
expect_equal(nrow(filtered.issues), 41)
## there are now 43 issue events remaining, since 10 issue events have been removed during filtering
expect_equal(nrow(filtered.issues), 43)
})

test_that("Filter bots from mail data", {
Expand Down
Loading

0 comments on commit 5febbda

Please sign in to comment.