-
Notifications
You must be signed in to change notification settings - Fork 242
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
fix: don't delete chat for blocked contacts #2612
Conversation
Pull Request Checklist
|
@saledjenic Thanks for the raising the PR! |
@cammellos let's discuss it then... at this moment, properties (coming from New design, at least for the desktop app, has more granular contact section view, there are the following views and condition what contacts belong to what view:
Based on above a change made in protocol/contact.go was necessary, otherwise after unblocking a blocked contact it would be treated as a new strange contact instead of being added to the group it belonged to before we make it blocked. The reason why I did changes in protocol/message_persistence.go and protocol/messenger_contacts.go cause if at the moment of blocking contact you have @cammellos that's how we do it in the desktop app. Any suggestion is welcomed, also you know who else we should include in this discussion if needed.
Even if we play with the above mentioned flags on the desktop app side, and make it work somehow that way, we cannot have consistent state among two app starts if we don't update |
@saledjenic Thanks for the explanation. It seems like there's two different concerns at play, one is how contacts will be looking like once we implement all the different states that you mentioned, the other is how to handle blocking/unblocking contacts. In terms of blocking contacts, looks like there's some discrepancies on how mobile & desktop are handling the UI/UX, specifically:
In the case of mobile, the chat is removed as soon as the RPC is successful, so the behavior is consistent and it looks like it does not result in the issue you see on desktop, so I think in this case it looks like you can adapt the same behavior client side on desktop? (We want to remove blocked users' messages and chat because one of the reason you might block a contact is spam, or dos of the app, and messages/chat might have an impact on it).
This seems to be a bit of a choice we want to make, in terms of UX, we decided previously that if you block someone that is in your contacts, you also want to remove them from your contacts, the argument is that those two options go almost always together, therefore when/if unblocking the contact, it should not be restored to your previous state. (We can discuss this choice, though mind this is a ui/ux edge case most likely) Just to understand, is this behavior currently resulting in some issues on desktop? |
I've thought the request is to have the app in the same state among multiple runs. And that is not possible (in case the But if request is to not display blocked chats, then we're good, we just need to revert changes done in
I agree, that was a request, but is that still a request considering that we have a new design now? If we unblock a
Referring to the status-im/status-desktop#5198 the thing why we are not able to receive messages for the user after we unblock it (in case we don't restart the app) is that @cammellos all in all based on what is discussed here, now the question is what do we want to achieve? Also to have all this set up properly according to the new design requirements we will need more new properties for a contact, but what do you propose so far? |
Do you receive a notification in the activity center? That should be the one we use on mobile in this case, since the chat is inactive
We will definitely need to add some of the fields you were mentioning, some of them I am working on (for example the time a contact request was sent), but probably the best place for conversation is in the PRs we are going to make those changes ( I am working on https://github.com/status-im/status-go/tree/feature/mutual-contact-requests ), but any suggestion is welcome |
@cammellos a notification that user is blocked? All in all, if I leave in this PR only changes done here protocol/contact.go, and revert other two files, is that ok from your side? |
@cammellos closing this cause we temporary proceeded with "desktop only" solution. |
No description provided.