Description
The saros view only shows "not connected" but in fact there is a connection and an invitation can be sent using the "Share with" button in the project view. It's also possible to be in a session without having it shown in the GUI. So the GUI is not showing the current internal state.
Reproduction
- Have a project opened
- In the saros view, connect to the XMPP server
- File > Close Project
- Choose to open the same or another project
- Note the saros view showing "not connected"
- Try to initiate a session via the "Share with" button which should work unless there is not contact online
or
- Have a project opened
- In the saros view, connect to the XMPP server
- Initiate a session with a contact
- Have the contact cancel the invitation, you're now in an "empty" session
- File > Close Project
- Choose to open the same or another (or a new) project
- Note the saros view not indicating that you're in a session, but internally you still are (to test this have a contact send an invitation which gets automatically rejected with the message that you're already in a session)
Expected Behaviour
The saros view should reflect the correct current internal status, even after closing and (re)opening a project.
Why is this specific to the connection state presentation. Reading your reproduction steps the first think that comes into my mind is that this issue may affect the whole Saros GUI in IntelliJ.
I'm not sure I fully understand you. Are you aiming at that I should broaden the scope of this bug?
This is what I observed, I don't know whether other parts of the GUI are affected/involved and if so, in which way.
Could you elaborate, please?
What happens if you close the project during a session ? If the session is terminated than it seems that only the connection part of GUI is broken. If the session remains it may also affect other GUI parts.
Ah ok. The session is not terminated. I edited the ticket. Feel free to do the same if you see room for improvement.
Diff:
I can provide you a simple solution to the problem. If it is possible to hook into the closing opening mechanism of a project you can just call ConnectionHandler#disconnect(). This will bring you back to a stable state. It is more like a hack/workaround but it fulfill its needs.
And I am the wrong person to ask for anything in the IntelliJ part of Saros.
e287343433d920f6589bcb05da863a372931972b