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

Bug fixes for ListChangeDrafts and ListChangeComments #9

Merged
merged 2 commits into from
Jul 20, 2016

Conversation

opalmer
Copy link
Contributor

@opalmer opalmer commented Jul 19, 2016

This PR contains two bug fixes. First it updates ListChangeComments to query the correct endpoint (it was changes/<change id>/in).

Second,ListChangeDrafts and ListChangeComments were expecting a response from Gerrit like this:

  {
    "file1": {<comment1>},
    "file2": {<comment2>},
  }

When in fact Gerrit will send this:

  {
    "file1": [{<comment1>}, {<comment2>}],
    "file2": [{<comment3>}, {<comment4>}]
  }

References:

@opalmer
Copy link
Contributor Author

opalmer commented Jul 19, 2016

@andygrunwald I checked Gerrit's docs and it appears the API has always responded with a list (or at least it has since 2.11). I guess this just slipped through because nobody has tried using these parts of the API yet heh.

@andygrunwald
Copy link
Owner

andygrunwald commented Jul 20, 2016

Thank you @opalmer.
I think this part was never used by someone. Thanks for catching this.
Gimme a few more minutes. I will merge it today and fix the tests immediately.

@andygrunwald andygrunwald merged commit 7ad61eb into andygrunwald:master Jul 20, 2016
@andygrunwald
Copy link
Owner

Merged.
Thank you @opalmer

@opalmer
Copy link
Contributor Author

opalmer commented Jul 20, 2016

Anytime, thanks!

@opalmer opalmer deleted the comments_bugfix branch July 20, 2016 15:05
@opalmer opalmer modified the milestone: 0.1.0 Oct 8, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants