Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Jira: Add functionality to get comments on an issue #1064

Merged
merged 5 commits into from
Oct 28, 2022

Conversation

martynbristow
Copy link
Contributor

Implement:

  • issue_get_comments(issue_id)
  • issue_get_comment(issue_id, comment_id)
  • issues_get_comments_by_id(comment_id, [comment_id ...])

Implement:

 - issue_get_comments(issue_id)
 - issue_get_comment(issue_id, comment_id)
 - issues_get_comments_by_id(comment_id, [comment_id ...])
Implement:

 - issue_get_comments(issue_id)
 - issue_get_comment(issue_id, comment_id)
 - issues_get_comments_by_id(comment_id, [comment_id ...])

Signed-off-by: Martyn Bristow <martyn.bristow@gmail.com>
Implement:

 - issue_get_comments(issue_id)
 - issue_get_comment(issue_id, comment_id)
 - issues_get_comments_by_id(comment_id, [comment_id ...])

Signed-off-by: Martyn Bristow <martyn.bristow@gmail.com>
@isaac-philip
Copy link
Contributor

I can have a look at this.

Copy link
Contributor

@isaac-philip isaac-philip left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great work! looks good, just a small name change if we can have it, thanks

print(comments)

print("\n*Get a set of comments*")
comments = jira.issues_get_comments_by_id(10000, 10002)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just a suggestion for the naming of function,
keeping in line with the single comment function naming convention,
could we keep multiple comments for the single issue named as,
issue_get_comments_selective rather than issues_get_comments_by_id
to help us understand that it is multiple selected comments for single issue.
Or some other better name? because i believe the filtering would always be based on the comment_id so keeping by_id mite be redundant here.

because it would always be comments drawn for the single issue and not multiple one if i understand correctly.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, I'm happy to change it to this. My only reason for choosing: issues_get_comments_by_id was to be consistent with the Atlassian JIRA API docs: https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-comments/#api-rest-api-3-comment-list-post

issues_get_comments_by_ids is still a bit weak, so I'll consider selective unless I have an idea

I also chose: issues_get_comments rather than get_issue_comments to match some existing code

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that sounds fine then, looks good to me for merge, thanks!

@isaac-philip
Copy link
Contributor

Please have final review and merge if good @gonchik

@gonchik gonchik merged commit 676c323 into atlassian-api:master Oct 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants