Skip to content

Next

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
    • Help
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
  • Sign in / Register
Minds Backend - Engine
Minds Backend - Engine
  • Project
    • Project
    • Details
    • Activity
    • Releases
    • Cycle Analytics
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Charts
    • Locked Files
  • Issues 142
    • Issues 142
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 28
    • Merge Requests 28
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
    • Charts
  • Registry
    • Registry
  • Packages
    • Packages
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Minds
  • Minds Backend - EngineMinds Backend - Engine
  • Issues
  • #488

Closed
Open
Opened 3 months ago by Jake Passi@JakePassi
  • Report abuse
  • New issue
Report abuse New issue

(bug): User is not marked as blocked after blocking in messenger

Summary

Reported by Ubertesters.

Steps to reproduce

  1. In messenger open a chat and choose block.
  2. Close the chat window.
  3. Open chat window again.

Platform information

Laptop windows 10, Chrome

Username: yahya94

What is the current bug behavior?

  1. Second party is not marked as blocked.
  2. User is able to block second party again.
  3. Second party is not receiving the messages.
  4. User is unable to unblock second party.

What is the expected correct behavior?

  1. Second party should be marked as blocked.
  2. User should not be able to block second party again.
  3. User should not be able to send messages.
  4. User should be able to unblock Second party.

Relevant logs and/or screenshots

https://dashboard.ubertesters.com/uploads/8463/11810/issues/64/153839/deeshanib%20_%20Minds%20(1).mp4

Possible fixes

(If you can, link to the line of code that might be responsible for the problem)

Please solve the reCAPTCHA

We want to be sure it is you, please confirm you are not a robot.

Related issues
0

    Related merge requests
    1
    • [Sprint/FunnyFrog](bug): Fixed bug that was stopping blocking from working #488
      !185
      sprint: Funny Frog
      Milestone
      sprint: Funny Frog
      1 day remaining
      (June 5, 2019)
    When this merge request is accepted, this issue will be closed automatically.
    • Jake Passi @JakePassi added 1 - High P - Messenger T - Bug labels 3 months ago

      added 1 - High P - Messenger T - Bug labels

    • Mark Harding
      Mark Harding @markeharding · 3 months ago
      Owner

      Can we get usernames between all interacted accounts on all reports?

    • Mark Harding
      Mark Harding @markeharding · 3 months ago
      Owner

      @JakePassi ^

    • Mark Harding @markeharding assigned to @benhayward.ben 3 months ago

      assigned to @benhayward.ben

    • Mark Harding @markeharding changed weight to 2 3 months ago

      changed weight to 2

    • Mark Harding @markeharding changed milestone to %sprint: Subscribers 3 months ago

      changed milestone to %sprint: Subscribers

    • Mark Harding @markeharding added S - Backlog label 3 months ago

      added S - Backlog label

    • Jake Passi
      Jake Passi @JakePassi · 3 months ago

      @yahya94 and @PEDROTM

    • Ben Hayward @benhayward.ben added S - InProgress label and removed S - Backlog label 3 months ago

      added S - InProgress label and removed S - Backlog label

    • Ben Hayward @benhayward.ben added S - Review label 3 months ago

      added S - Review label

    • Ben Hayward @benhayward.ben added S - Follow Up label and removed S - Review label 3 months ago

      added S - Follow Up label and removed S - Review label

    • Ben Hayward
      Ben Hayward @benhayward.ben · 3 months ago
      Developer

      Dug into this a bit more and it seems that the problem is that when the conversation is loaded, the blocked status is incorrect. Prior to the image below I started a conversation between 2 browsers. I tested that the messages could be sent and then blocked my secondary account. Looking at the image below, (1) shows the response from the conversation endpoint on load. (2) shows the result of trying to send a message to my primary account.

      I need to see if somebody can check on their systems that this is not an issue with my local setup, as I find it strange. Looking at the PHP, This value is gotten from the ACL, which I am sceptical is really is at fault.

      Edited by Ben Hayward 3 months ago
    • Ben Hayward @benhayward.ben added S - Backlog label and removed S - InProgress label 3 months ago

      added S - Backlog label and removed S - InProgress label

    • Ben Hayward @benhayward.ben added S - InProgress label and removed S - Backlog label 3 months ago

      added S - InProgress label and removed S - Backlog label

    • Ben Hayward @benhayward.ben removed S - InProgress label 3 months ago

      removed S - InProgress label

    • Ben Hayward
      Ben Hayward @benhayward.ben · 2 months ago
      Developer

      @markeharding

    • Mark Harding
      Mark Harding @markeharding · 2 months ago
      Owner

      Could you replicate the issue on production?

    • Ben Hayward
      Ben Hayward @benhayward.ben · 2 months ago
      Developer

      @markeharding Yep, this bug does appear from my perspective (or did when checked) happen on production.

      Edited by Ben Hayward 2 months ago
    • Mark Harding
      Mark Harding @markeharding · 1 week ago
      Owner

      What is the status here?

    • Ben Hayward @benhayward.ben changed milestone to %sprint: Funny Frog 1 week ago

      changed milestone to %sprint: Funny Frog

    • Ben Hayward
      Ben Hayward @benhayward.ben · 1 week ago
      Developer

      Will take another look at this this week as my domain knowledge is better now. If I cannot come to a solution in a timely manner I'll hand it off to a more senior developer.

    • Ben Hayward @benhayward.ben added S - InProgress label and removed S - Follow Up label 1 week ago

      added S - InProgress label and removed S - Follow Up label

    • Ben Hayward @benhayward.ben added S - Backlog label and removed S - InProgress label 1 week ago

      added S - Backlog label and removed S - InProgress label

    • Ben Hayward @benhayward.ben added S - InProgress label and removed S - Backlog label 6 days ago

      added S - InProgress label and removed S - Backlog label

    • Ben Hayward @benhayward.ben changed weight to 4 6 days ago

      changed weight to 4

    • Ben Hayward @benhayward.ben added S - Backlog label and removed S - InProgress label 6 days ago

      added S - Backlog label and removed S - InProgress label

    • Ben Hayward @benhayward.ben added S - InProgress label and removed S - Backlog label 6 days ago

      added S - InProgress label and removed S - Backlog label

    • Ben Hayward
      Ben Hayward @benhayward.ben · 6 days ago
      Developer

      I'm unable to see any errors in php-fpm, upon blocking a user, going to investigate why that is in the engine.

      Update on that: Can't see anything of issue, and looking at Git Blame it's been a while since those changes were made. Noticed that the engine is storing the block correctly locally as after blocking I cannot access the users profile - the front-end must be getting incorrect data or interpreting it wrongly.

      Further update: The banned status is returned incorrectly from the conversations endpoint. Looking at the endpoint we see

      if (!Security\ACL::_()->interact(Core\Session::getLoggedInUser(), $participant['guid'])) {
                              $blocked = true;
                              break;
      }

      Given this, I believe the issue to be in, as it appears to be returning incorrectly for the above conditional https://gitlab.com/benhayward.ben/engine/blame/master/Core/Security/ACL.php

      Edited by Ben Hayward 5 days ago
    • Ben Hayward @benhayward.ben changed milestone to %sprint: Funny Frog 33 minutes ago

      changed milestone to %sprint: Funny Frog

    • Ben Hayward @benhayward.ben changed weight to 4 33 minutes ago

      changed weight to 4

    • Ben Hayward @benhayward.ben moved from front#383 (closed) 33 minutes ago

      moved from front#383 (closed)

    • Ben Hayward @benhayward.ben mentioned in merge request !185 25 minutes ago

      mentioned in merge request !185

    • You're only seeing other activity in the feed. To add a comment, switch to one of the following options.
    Please register or sign in to reply
    Assignee
    Ben Hayward's avatar Ben Hayward @benhayward.ben
    Assign to
    None
    Epic
    None
    sprint: Funny Frog
    Milestone
    sprint: Funny Frog
    Assign milestone
    None
    Time tracking
    No estimate or time spent
    None
    Due date
    None
    4
    Labels
    1 - High P - Messenger S - Review T - Bug
    Assign labels
    • View project labels
    4
    Weight
    4
    Confidentiality
    Not confidential
    Lock issue
    Unlocked
    3
    3 participants
    user avatar
    Ben Hayward
    user avatar
    Mark Harding
    user avatar
    Jake Passi
    Reference: minds/engine#488