Skip to content

Commit a795752

Browse files
fix
1 parent 9977c01 commit a795752

File tree

2 files changed

+20
-20
lines changed

2 files changed

+20
-20
lines changed

issues_parser.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,11 @@ class IssueData:
3636

3737
@dataclass(kw_only=True, frozen=True)
3838
class IssueDataWithComment(IssueData):
39-
body: str = ''
40-
created_at: str = ''
41-
author_name: str = ''
42-
author_login: str = ''
43-
author_email: str = ''
39+
comment_body: str = ''
40+
comment_created_at: str = ''
41+
comment_author_name: str = ''
42+
comment_author_login: str = ''
43+
comment_author_email: str = ''
4444

4545

4646
def get_connected_pulls(issue_number, repo_owner, repo_name, token):
@@ -172,11 +172,11 @@ def log_issue_and_comments(csv_name, issue_data: IssueData, comments):
172172
for comment in comments:
173173
comment_data = IssueDataWithComment(
174174
**asdict(issue_data),
175-
body=comment.body,
176-
created_at=str(comment.created_at),
177-
author_name=comment.author.username,
178-
author_login=comment.author.login,
179-
author_email=comment.author.email,
175+
comment_body=comment.body,
176+
comment_created_at=str(comment.created_at),
177+
comment_author_name=comment.author.username,
178+
comment_author_login=comment.author.login,
179+
comment_author_email=comment.author.email,
180180
)
181181
comment_data = asdict(comment_data)
182182

pull_requests_parser.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -39,11 +39,11 @@ class PullRequestData:
3939

4040
@dataclass(kw_only=True, frozen=True)
4141
class PullRequestDataWithComment(PullRequestData):
42-
body: str = ''
43-
created_at: str = ''
44-
author_name: str = ''
45-
author_login: str = ''
46-
author_email: str = ''
42+
comment_body: str = ''
43+
comment_created_at: str = ''
44+
comment_author_name: str = ''
45+
comment_author_login: str = ''
46+
comment_author_email: str = ''
4747

4848

4949
def get_related_issues(pull_request_number, repo_owner, repo_name, token):
@@ -166,11 +166,11 @@ def get_info(obj, attr):
166166
for comment in comments:
167167
comment_data = PullRequestDataWithComment(
168168
**asdict(pr_data),
169-
body=comment.body,
170-
created_at=str(comment.created_at),
171-
author_name=comment.author.name,
172-
author_login=comment.author.login,
173-
author_email=nvl(comment.author.email),
169+
comment_body=comment.body,
170+
comment_created_at=str(comment.created_at),
171+
comment_author_name=comment.author.name,
172+
comment_author_login=comment.author.login,
173+
comment_author_email=nvl(comment.author.email),
174174
)
175175
comment_data = asdict(comment_data)
176176

0 commit comments

Comments
 (0)