Status images do not accurately represent users for all new pull requests.

Issue #19 resolved
Jonathan Schwietert created an issue

Another developer recently opened three pull requests and added me as a reviewer. Shortly after creating them he noticed that my image showed a red "X" indicating I had blocked it. There is no history entry of my user blocking the request and, in my view, the "Block" button is not depressed - you can see this in the screenshots. Now as you can also see in the screenshots, only two out of the three new pull requests the developer opened had this problem - so i'm not sure how repeatable it is. So, if i then click "Block" (nothing changes other than the button being depressed) and "Unblock" my image is corrected in the pull request view but not in my inbox. I know you said that it sometimes takes a refresh to show up, so i did that and it still shows be as blocked - even after going to the home page. In fact, it seems to continue the behavior noted below - see screenshot for 2.58.33 pm. Also, I included a screenshot (2.54.42 pm) of the hover-over for the block button stating "Block this pull requestundefined (Type 'b')" - i thought that was odd.

Unfortunately thats not our only problem. Starting off from the Stash homepage if i click the "inbox" icon I get the drop down in the screenshot for 2.47.28 pm. Next, if i click on one of the new pull requests from that drop down I see what's in the screenshot for 2.47.49 pm. Notice there is no red "X" on my image. Now, if I click on my inbox from this view, it covers up that image from the pull request view and shows what is in the screenshot for 2.47.57 pm. If i just click off of the inbox to get it to go away i then see whats in screenshot for 2.48.08 pm. Notice the red "X" is now present on my image. This odd missing red "X" is very repeatable.

Sorry for all these details being in one ticket but i'm not sure if they're the same bug or not.

Comments (14)

  1. Georgy Bolyuba

    Does the author of your pull requests see you as "blocked the pull request" on page where all pull requests for given repo are listed? Every pull request on that page will have icons of all reviewers and it your status should be shown there

  2. Donovan Levinson

    When I load the tab for Pull requests on a repo the status is displayed correctly. However, with this page open, if I click on the inbox drop down it shows the reviewer as blocked and updates the image on the repo pull requests tab to also show as blocked.

  3. Georgy Bolyuba

    Yes, you seems to get different results for two REST calls (two of these ajax calls use different REST calls)

  4. Georgy Bolyuba

    Logged as yourself, can you check rest/block-pull-request/1.0/blocked-reviewers-for-inbox url? It should return json for requests with block flags

  5. Georgy Bolyuba

    I am trying different scenarios, but cannot reproduce this so far. I am also preparing a new version that will log more than the current one. If I am not able to reproduce the issue in next day or two at least I will push out version with better logging to help track this down

  6. Georgy Bolyuba

    I found the source of the problem with inbox. At this point however I cannot fix it (I need to think of a clever way to work with inbox plugin, something I am doing for 2.0.0). Pull request id is unique in the scope of the repository, there is no way to tell repository id from the content of inbox right now, only pull request id. The picture that Donovan is seeing is caused by you blocking pull requests with same ids (5 is one of them) in other repos. I will turn this function off in patch version and enable it again once I find a way to implement it properly

  7. Georgy Bolyuba

    I pushed 1.2.3 with inbox icon disabled for now. I also changed logic around displaying block icon for reviewers on pull request page.Still not able to reproduce the issue you had with block icon on pull request page. Can you please retest it using 1.2.3 version?

  8. Jonathan Schwietert reporter

    The status seems to be accurately represented in the pull request page as well as the repo's pull request summary page. Like you mentioned, the inbox no longer shows blocks.

  9. Jonathan Schwietert reporter

    Just noticed that you found the bug in your comment on 1/22 - thats great news! Even though it can't be in 1.x.x its always nice to understand the source of the problem. Thanks for your responsiveness and attention to detail - I'm now looking forward to v. 2 even more :)

  10. Log in to comment