Open taoeffect opened 3 months ago
Identify the problem and fix.
This is tricker than it sounds. As far as identifying the issue, there's two I can point at.
Refreshing the page should finish the joining process even if the websocket got interrupted.
This is also a tricky change. The joining process can't be finished because the contract events have already been processed (even though they failed) and won't be processed again. I'm not sure it's a good idea to reprocess failed events and also not sure how we could detect which events should be fixed by refreshing the page either. Do you have specific ideas of what should be done?
We can discuss this next time we meet, or feel free to reply here what you envision the solution to be to the last point.
I'm not sure it's a good idea to reprocess failed events and also not sure how we could detect which events should be fixed by refreshing the page either. Do you have specific ideas of what should be done?
I agree reprocessing failed events doesn't make sense.
As far as specific ideas, perhaps the app could detect that a join attempt was made that failed, and then resend any actions or events that need to be resent/re-emmitted.
I suggest proceeding like this:
join
that cause you to be stuck and proceeding when you shouldn't because processing failedcould detect that a join attempt was made that failed
. It sounds like the kind of situation the persistent queue was supposed to solveSounds good 👍
Problem
During development (
grunt dev
), I signed up a user. I ran into this bug (and this related issue). This means that I was able to create the identity contract, but not subscribe to it. I continued then to create the group contract, and arrived at the /pending-approval page.I then saw
TypeError: can't access property "_vm", state is undefined
:Here are some related sections of code from that stacktrace:
utils.js:18
:chatroom.js:71
:group.js:602
:utils.js:133
:Upon refresh the web socket seemed to connect, but there were no more errors and I was still at the
/pending-approval
page.It seems like part of the joining group process got interrupted. Perhaps some data is not there to trigger the related key messages from
group/join
.So I grabbed the
state/vuex/state
:And
chelonia/rootState
:Here is the diff:
And here are the console logs:
Solution
Identify the problem and fix.
Refreshing the page should finish the joining process even if the websocket got interrupted.