From 2613ddb17956fcc269abad8d812fb3905cb310f8 Mon Sep 17 00:00:00 2001 From: Magnesium12 Date: Tue, 9 Aug 2022 23:17:34 +0530 Subject: [PATCH 01/10] test: Add unittests for 6 github_parsers. --- tests/github/data.json | 194 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 194 insertions(+) diff --git a/tests/github/data.json b/tests/github/data.json index c5259f1..76609e7 100644 --- a/tests/github/data.json +++ b/tests/github/data.json @@ -28,5 +28,199 @@ "type": "EventType.BRANCH_CREATED", "user": "" } + ], + "branch_delete": [ + { + "event_type": "delete", + "raw_json": { + "ref": "branch-name", + "ref_type": "branch", + "pusher_type": "user", + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "example-user" + } + } + }, + { + "comments": "None", + "commits": "None", + "issue": "None", + "links": "None", + "pull_request": "None", + "ref": "branch-name", + "repo": "", + "reviewers": "None", + "status": "None", + "type": "EventType.BRANCH_DELETED", + "user": "" + } + ], + "commit_comment": [ + { + "event_type": "commit_comment", + "raw_json": { + "action": "created", + "comment": { + "html_url": "https://github.com/example-org/example-repo/commit/4d93b5294b201237#commitcomment-12345678", + "user": { + "login": "user-who-commented" + }, + "commit_id": "4d93b5294b201237", + "body": "comment content" + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-commented" + } + } + }, + { + "comments": "['comment content']", + "commits": "[<|https://github.com/example-org/example-repo/commit/4d93b529>]", + "issue": "None", + "links": "[]", + "pull_request": "None", + "ref": "None", + "repo": "", + "reviewers": "None", + "status": "None", + "type": "EventType.COMMIT_COMMENT", + "user": "" + } + ], + "fork": [ + { + "event_type": "fork", + "raw_json": { + "forkee": { + "owner": { + "login": "user-who-forked" + }, + "html_url": "https://github.com/user-who-forked/example-repo" + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + } + } + }, + { + "comments": "None", + "commits": "None", + "issue": "None", + "links": "[]", + "pull_request": "None", + "ref": "None", + "repo": "", + "reviewers": "None", + "status": "None", + "type": "EventType.FORK", + "user": "" + } + ], + "push": [ + { + "event_type": "push", + "raw_json": { + "ref": "refs/heads/branch-name", + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "pusher": { + "name": "user-who-pushed" + }, + "sender": { + "login": "user-who-pushed" + }, + "commits": [ + { + "id": "f30421319e41a3a", + "message": "commit-message1" + }, + { + "id": "5g0521417e40i37d9", + "message": "commit-message2" + } + + ] + } + }, + { + "comments": "None", + "commits": "[, ]", + "issue": "None", + "links": "None", + "pull_request": "None", + "ref": "branch-name", + "repo": "", + "reviewers": "None", + "status": "None", + "type": "EventType.PUSH", + "user": "" + } + ], + "star-add": [ + { + "event_type": "star", + "raw_json": { + "action": "created", + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-starred" + } + } + }, + { + "comments": "None", + "commits": "None", + "issue": "None", + "links": "None", + "pull_request": "None", + "ref": "None", + "repo": "", + "reviewers": "None", + "status": "None", + "type": "EventType.STAR_ADDED", + "user": "" + } + ], + "star-remove": [ + { + "event_type": "star", + "raw_json": { + "action": "deleted", + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-unstarred" + } + } + }, + { + "comments": "None", + "commits": "None", + "issue": "None", + "links": "None", + "pull_request": "None", + "ref": "None", + "repo": "", + "reviewers": "None", + "status": "None", + "type": "EventType.STAR_REMOVED", + "user": "" + } ] } From 00e6f7847781eaeb70b3454a18b9207e2e8de2b9 Mon Sep 17 00:00:00 2001 From: Magnesium12 Date: Tue, 9 Aug 2022 23:21:30 +0530 Subject: [PATCH 02/10] test: Add unittests for 6 github_parsers. --- tests/github/data.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/github/data.json b/tests/github/data.json index 76609e7..ddbb699 100644 --- a/tests/github/data.json +++ b/tests/github/data.json @@ -149,7 +149,7 @@ "id": "5g0521417e40i37d9", "message": "commit-message2" } - + ] } }, From 3bdb0682ba7770e6d5f1670bad6d281f318a3122 Mon Sep 17 00:00:00 2001 From: BURG3R5 <77491630+BURG3R5@users.noreply.github.com> Date: Tue, 9 Aug 2022 23:05:53 +0530 Subject: [PATCH 03/10] fix(test): Fix serializer to properly parse iterators. --- tests/utils/serializers.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/utils/serializers.py b/tests/utils/serializers.py index dc4008f..c0c3516 100644 --- a/tests/utils/serializers.py +++ b/tests/utils/serializers.py @@ -6,5 +6,8 @@ def github_event_serializer(github_event: GitHubEvent) -> dict[str, Any]: serialized = {} for var, value in vars(github_event).items(): - serialized[var] = str(value) + if isinstance(value, (list, tuple, set)): + serialized[var] = [str(v) for v in value] + else: + serialized[var] = str(value) return serialized From a47ebed8422d47d8681ed526547345137e950aa2 Mon Sep 17 00:00:00 2001 From: BURG3R5 <77491630+BURG3R5@users.noreply.github.com> Date: Tue, 9 Aug 2022 23:30:07 +0530 Subject: [PATCH 04/10] chore: Do not initialize unnecessary attributes in `GitHubEvent`. --- bot/models/github/event.py | 68 ++++++++++++++++++++++---------------- tests/github/data.json | 7 ---- 2 files changed, 40 insertions(+), 35 deletions(-) diff --git a/bot/models/github/event.py b/bot/models/github/event.py index 67c6b53..832ed8e 100644 --- a/bot/models/github/event.py +++ b/bot/models/github/event.py @@ -1,6 +1,7 @@ """ Model class that can store all relevant info about all events that the project handles. """ +from typing import Optional from ..link import Link from . import Commit, EventType, Issue, PullRequest, Ref, Repository, User @@ -25,37 +26,48 @@ class GitHubEvent: :keyword links: List of miscellaneous links. """ + type: EventType + repo: Repository + status: Optional[str] + issue: Optional[Issue] + pull_request: Optional[PullRequest] + ref: Optional[Ref] + user: Optional[User] + comments: Optional[list[str]] + commits: Optional[list[Commit]] + links: Optional[list[Link]] + reviewers: Optional[list[User]] + def __init__(self, event_type: EventType, repo: Repository, **kwargs): self.type = event_type self.repo = repo - self.status: str | None = kwargs.get("status", None) - - self.issue: Issue | None = kwargs.get("issue", None) - self.pull_request: PullRequest | None = kwargs.get( - "pull_request", - None, - ) - self.ref: Ref | None = kwargs.get("ref", None) - self.user: User | None = kwargs.get("user", None) - - self.comments: list[str] | None = kwargs.get("comments", None) - - self.commits: list[Commit] | None = kwargs.get("commits", None) - self.links: list[Link] | None = kwargs.get("links", None) - self.reviewers: list[User] | None = kwargs.get("reviewers", None) + if "status" in kwargs: + self.status = kwargs["status"] + if "issue" in kwargs: + self.issue = kwargs["issue"] + if "pull_request" in kwargs: + self.pull_request = kwargs["pull_request"] + if "ref" in kwargs: + self.ref = kwargs["ref"] + if "user" in kwargs: + self.user = kwargs["user"] + if "comments" in kwargs: + self.comments = kwargs["comments"] + if "commits" in kwargs: + self.commits = kwargs["commits"] + if "links" in kwargs: + self.links = kwargs["links"] + if "reviewers" in kwargs: + self.comments = kwargs["reviewers"] def __str__(self): - return f"""( - type={self.type}, - repo={self.repo.name}, - status={self.status}, - issue={self.issue.title}, - pull_request={self.pull_request.title}, - ref={self.ref.name}, - user={self.user.name}, - comments={[comment for comment in self.comments]}, - commits={[commit.message for commit in self.commits]}, - links={[link.url for link in self.links]}, - users={[reviewer.name for reviewer in self.reviewers]}, - )""" + string = "" + for var, value in vars(self).items(): + string += var + "=" + if isinstance(value, (list, tuple, set)): + string += str([str(v) for v in value]) + else: + string += str(value) + string += ", " + return "(" + string[:-2] + ")" diff --git a/tests/github/data.json b/tests/github/data.json index ddbb699..07449f4 100644 --- a/tests/github/data.json +++ b/tests/github/data.json @@ -16,15 +16,8 @@ } }, { - "comments": "None", - "commits": "None", - "issue": "None", - "links": "None", - "pull_request": "None", "ref": "branch-name", "repo": "", - "reviewers": "None", - "status": "None", "type": "EventType.BRANCH_CREATED", "user": "" } From 862ef2532e89a62544960856275160748ccdeb8b Mon Sep 17 00:00:00 2001 From: Magnesium12 Date: Wed, 10 Aug 2022 00:06:30 +0530 Subject: [PATCH 05/10] fix(test): Remove attributes with value None --- tests/github/data.json | 41 ----------------------------------------- 1 file changed, 41 deletions(-) diff --git a/tests/github/data.json b/tests/github/data.json index 07449f4..17518db 100644 --- a/tests/github/data.json +++ b/tests/github/data.json @@ -39,15 +39,8 @@ } }, { - "comments": "None", - "commits": "None", - "issue": "None", - "links": "None", - "pull_request": "None", "ref": "branch-name", "repo": "", - "reviewers": "None", - "status": "None", "type": "EventType.BRANCH_DELETED", "user": "" } @@ -77,13 +70,8 @@ { "comments": "['comment content']", "commits": "[<|https://github.com/example-org/example-repo/commit/4d93b529>]", - "issue": "None", "links": "[]", - "pull_request": "None", - "ref": "None", "repo": "", - "reviewers": "None", - "status": "None", "type": "EventType.COMMIT_COMMENT", "user": "" } @@ -105,15 +93,8 @@ } }, { - "comments": "None", - "commits": "None", - "issue": "None", "links": "[]", - "pull_request": "None", - "ref": "None", "repo": "", - "reviewers": "None", - "status": "None", "type": "EventType.FORK", "user": "" } @@ -147,15 +128,9 @@ } }, { - "comments": "None", "commits": "[, ]", - "issue": "None", - "links": "None", - "pull_request": "None", "ref": "branch-name", "repo": "", - "reviewers": "None", - "status": "None", "type": "EventType.PUSH", "user": "" } @@ -175,15 +150,7 @@ } }, { - "comments": "None", - "commits": "None", - "issue": "None", - "links": "None", - "pull_request": "None", - "ref": "None", "repo": "", - "reviewers": "None", - "status": "None", "type": "EventType.STAR_ADDED", "user": "" } @@ -203,15 +170,7 @@ } }, { - "comments": "None", - "commits": "None", - "issue": "None", - "links": "None", - "pull_request": "None", - "ref": "None", "repo": "", - "reviewers": "None", - "status": "None", "type": "EventType.STAR_REMOVED", "user": "" } From acd76ad8c629a71843be30fd718dc732bac8ef33 Mon Sep 17 00:00:00 2001 From: Magnesium12 Date: Fri, 12 Aug 2022 21:24:15 +0530 Subject: [PATCH 06/10] test: Add unittests for github_parsers. --- tests/github/data.json | 352 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 345 insertions(+), 7 deletions(-) diff --git a/tests/github/data.json b/tests/github/data.json index 17518db..44be3bf 100644 --- a/tests/github/data.json +++ b/tests/github/data.json @@ -63,17 +63,17 @@ "html_url": "https://github.com/example-org/example-repo" }, "sender": { - "login": "user-who-commented" + "login": "example-user" } } }, { - "comments": "['comment content']", - "commits": "[<|https://github.com/example-org/example-repo/commit/4d93b529>]", - "links": "[]", + "comments": ["comment content"], + "commits": ["<|https://github.com/example-org/example-repo/commit/4d93b529>"], + "links": [""], "repo": "", "type": "EventType.COMMIT_COMMENT", - "user": "" + "user": "" } ], "fork": [ @@ -93,7 +93,7 @@ } }, { - "links": "[]", + "links": [""], "repo": "", "type": "EventType.FORK", "user": "" @@ -128,7 +128,7 @@ } }, { - "commits": "[, ]", + "commits": ["", ""], "ref": "branch-name", "repo": "", "type": "EventType.PUSH", @@ -174,5 +174,343 @@ "type": "EventType.STAR_REMOVED", "user": "" } + ], + "issue-open": [ + { + "event_type": "issues", + "raw_json": { + "action": "opened", + "issue": { + "html_url": "https://github.com/example-org/example-repo/issues/3", + "number": 3, + "title": "ExampleIssue", + "user": { + "login": "user-who-opened-issue" + } + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-opened-issue" + } + } + }, + { + "repo": "", + "type": "EventType.ISSUE_OPENED", + "user": "", + "issue": "" + } + ], + "issue-close": [ + { + "event_type": "issues", + "raw_json": { + "action": "closed", + "issue": { + "html_url": "https://github.com/example-org/example-repo/issues/3", + "number": 3, + "title": "ExampleIssue", + "user": { + "login": "user-who-closed-issue" + } + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-closed-issue" + } + } + }, + { + "repo": "", + "type": "EventType.ISSUE_CLOSED", + "user": "", + "issue": "" + } + ], + "issue-comment": [ + { + "event_type": "issue_comment", + "raw_json": { + "action": "created", + "issue": { + "html_url": "https://github.com/example-org/example-repo/issues/3", + "number": 3, + "title": "ExampleIssue" + }, + "comment": { + "html_url": "https://github.com/example-org/example-repo/issues/3#issuecomment-1234567890", + "body": "comment content" + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-commented" + } + } + }, + { + "repo": "", + "type": "EventType.ISSUE_COMMENT", + "user": "", + "issue": "", + "comments": ["comment content"], + "links": [""] + } + ], + "pull-close": [ + { + "event_type": "pull_request", + "raw_json": { + "action": "closed", + "number": 3, + "pull_request": { + "html_url": "https://github.com/example-org/example-repo/pull/3", + "number": 3, + "title": "ExamplePR", + "user": { + "login": "user-who-closed-PR" + }, + "merged": false + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + } + } + }, + { + "repo": "", + "type": "EventType.PULL_CLOSED", + "user": "", + "pull_request": "" + } + ], + "pull-merge": [ + { + "event_type": "pull_request", + "raw_json": { + "action": "closed", + "number": 3, + "pull_request": { + "html_url": "https://github.com/example-org/example-repo/pull/3", + "number": 3, + "title": "ExamplePR", + "user": { + "login": "user-who-merged-PR" + }, + "merged": true + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + } + } + }, + { + "repo": "", + "type": "EventType.PULL_MERGED", + "user": "", + "pull_request": "" + } + ], + "pull-open": [ + { + "event_type": "pull_request", + "raw_json": { + "action": "opened", + "number": 3, + "pull_request": { + "html_url": "https://github.com/example-org/example-repo/pull/3", + "number": 3, + "title": "ExamplePR", + "user": { + "login": "user-who-opened-PR" + } + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + } + } + }, + { + "repo": "", + "type": "EventType.PULL_OPENED", + "user": "", + "pull_request": "" + } + ], + "pull-ready": [ + { + "event_type": "pull_request", + "raw_json": { + "action": "review_requested", + "pull_request": { + "html_url": "https://github.com/example-org/example-repo/pull/3", + "number": 3, + "title": "ExamplePR", + "requested_reviewers": [ + { + "login": "reviewer1" + }, + { + "login": "reviewer2" + } + ] + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + } + } + }, + { + "repo": "", + "type": "EventType.PULL_READY", + "reviewers": ["",""], + "pull_request": "" + } + ], + "release": [ + { + "event_type": "release", + "raw_json": { + "action": "released", + "release": { + "tag_name": "example-tag" + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "example-user" + } + } + }, + { + "ref": "example-tag", + "repo": "", + "type": "EventType.RELEASE", + "status": "created", + "user": "" + } + ], + "review": [ + { + "event_type": "pull_request_review", + "raw_json": { + "action": "submitted", + "review": { + "state": "changes_requested" + }, + "pull_request": { + "html_url": "https://github.com/example-org/example-repo/pull/3", + "number": 3, + "title": "ExamplePR" + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "reviewer" + } + } + }, + { + "repo": "", + "type": "EventType.REVIEW", + "pull_request": "", + "status": "changes_requested", + "reviewers": [""] + } + ], + "review-comment": [ + { + "event_type": "pull_request_review_comment", + "raw_json": { + "action": "created", + "comment": { + "url": "https://api.github.com/repos/example-org/example-repo/pulls/comments/123456789", + "html_url": "https://github.com/example-org/example-repo/pull/3#discussion_r123456789", + "body": "comment content" + }, + "pull_request": { + "html_url": "https://github.com/example-org/example-repo/pull/3", + "number": 3, + "title": "ExamplePR" + }, + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-commented" + } + } + }, + { + "repo": "", + "type": "EventType.REVIEW_COMMENT", + "user": "", + "pull_request": "", + "comments": ["comment content"], + "links": [""] + } + ], + "tag-create": [ + { + "event_type": "create", + "raw_json": { + "ref": "example-tag", + "ref_type": "tag", + "pusher_type": "user", + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-created-tag" + } + } + }, + { + "ref": "example-tag", + "repo": "", + "type": "EventType.TAG_CREATED", + "user": "" + } + ], + "tag-delete": [ + { + "event_type": "delete", + "raw_json": { + "ref": "example-tag", + "ref_type": "tag", + "pusher_type": "user", + "repository": { + "full_name": "example-org/example-repo", + "html_url": "https://github.com/example-org/example-repo" + }, + "sender": { + "login": "user-who-deleted-tag" + } + } + }, + { + "ref": "example-tag", + "repo": "", + "type": "EventType.TAG_DELETED", + "user": "" + } ] } From 93aebc4903a6dd8d941ef00cb816c3264d8f1306 Mon Sep 17 00:00:00 2001 From: Magnesium12 Date: Fri, 12 Aug 2022 21:45:47 +0530 Subject: [PATCH 07/10] fix(test): Add None value in the list named link. --- tests/github/data.json | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/github/data.json b/tests/github/data.json index 44be3bf..e02c62a 100644 --- a/tests/github/data.json +++ b/tests/github/data.json @@ -53,7 +53,7 @@ "comment": { "html_url": "https://github.com/example-org/example-repo/commit/4d93b5294b201237#commitcomment-12345678", "user": { - "login": "user-who-commented" + "login": "example-user" }, "commit_id": "4d93b5294b201237", "body": "comment content" @@ -70,7 +70,7 @@ { "comments": ["comment content"], "commits": ["<|https://github.com/example-org/example-repo/commit/4d93b529>"], - "links": [""], + "links": [""], "repo": "", "type": "EventType.COMMIT_COMMENT", "user": "" @@ -93,7 +93,7 @@ } }, { - "links": [""], + "links": [""], "repo": "", "type": "EventType.FORK", "user": "" @@ -262,7 +262,7 @@ "user": "", "issue": "", "comments": ["comment content"], - "links": [""] + "links": [""] } ], "pull-close": [ @@ -464,7 +464,7 @@ "user": "", "pull_request": "", "comments": ["comment content"], - "links": [""] + "links": [""] } ], "tag-create": [ From 948f9f6e72ad7c2bd7aa652b2df7f68f3b1ee1b0 Mon Sep 17 00:00:00 2001 From: Magnesium12 Date: Fri, 12 Aug 2022 23:32:07 +0530 Subject: [PATCH 08/10] fix(github): Correct the Link of Review-comment GithubEvent. --- bot/github/github_parsers.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot/github/github_parsers.py b/bot/github/github_parsers.py index 84e2c58..55c5692 100644 --- a/bot/github/github_parsers.py +++ b/bot/github/github_parsers.py @@ -488,7 +488,7 @@ def cast_payload_to_event(event_type: str, json: JSON) -> GitHubEvent: link=json["pull_request"]["html_url"], ), comments=[json["comment"]["body"]], - links=[Link(url=json["comment"]["url"])], + links=[Link(url=json["comment"]["html_url"])], ) From 9686b83798e1923e660336ea32ba968a7f580ea2 Mon Sep 17 00:00:00 2001 From: BURG3R5 <77491630+BURG3R5@users.noreply.github.com> Date: Sun, 14 Aug 2022 16:56:00 +0530 Subject: [PATCH 09/10] fix(github): Improper assignment in `GitHubEvent`. --- bot/models/github/event.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bot/models/github/event.py b/bot/models/github/event.py index 832ed8e..9b62670 100644 --- a/bot/models/github/event.py +++ b/bot/models/github/event.py @@ -59,7 +59,7 @@ def __init__(self, event_type: EventType, repo: Repository, **kwargs): if "links" in kwargs: self.links = kwargs["links"] if "reviewers" in kwargs: - self.comments = kwargs["reviewers"] + self.reviewers = kwargs["reviewers"] def __str__(self): string = "" From 2ab22b082be83bee30b669884a67831de89802bc Mon Sep 17 00:00:00 2001 From: Magnesium12 Date: Mon, 15 Aug 2022 14:55:39 +0530 Subject: [PATCH 10/10] chore(test): Change names of all test cases to snake_case. --- tests/github/data.json | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/tests/github/data.json b/tests/github/data.json index e02c62a..6614955 100644 --- a/tests/github/data.json +++ b/tests/github/data.json @@ -135,7 +135,7 @@ "user": "" } ], - "star-add": [ + "star_add": [ { "event_type": "star", "raw_json": { @@ -155,7 +155,7 @@ "user": "" } ], - "star-remove": [ + "star_remove": [ { "event_type": "star", "raw_json": { @@ -175,7 +175,7 @@ "user": "" } ], - "issue-open": [ + "issue_open": [ { "event_type": "issues", "raw_json": { @@ -204,7 +204,7 @@ "issue": "" } ], - "issue-close": [ + "issue_close": [ { "event_type": "issues", "raw_json": { @@ -233,7 +233,7 @@ "issue": "" } ], - "issue-comment": [ + "issue_comment": [ { "event_type": "issue_comment", "raw_json": { @@ -265,7 +265,7 @@ "links": [""] } ], - "pull-close": [ + "pull_close": [ { "event_type": "pull_request", "raw_json": { @@ -293,7 +293,7 @@ "pull_request": "" } ], - "pull-merge": [ + "pull_merge": [ { "event_type": "pull_request", "raw_json": { @@ -321,7 +321,7 @@ "pull_request": "" } ], - "pull-open": [ + "pull_open": [ { "event_type": "pull_request", "raw_json": { @@ -348,7 +348,7 @@ "pull_request": "" } ], - "pull-ready": [ + "pull_ready": [ { "event_type": "pull_request", "raw_json": { @@ -434,7 +434,7 @@ "reviewers": [""] } ], - "review-comment": [ + "review_comment": [ { "event_type": "pull_request_review_comment", "raw_json": { @@ -467,7 +467,7 @@ "links": [""] } ], - "tag-create": [ + "tag_create": [ { "event_type": "create", "raw_json": { @@ -490,7 +490,7 @@ "user": "" } ], - "tag-delete": [ + "tag_delete": [ { "event_type": "delete", "raw_json": {