japazilian / multitype

Automatically exported from code.google.com/p/multitype
0 stars 0 forks source link

First FEU received has bad information #1

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Using the view driver (which sends out a character from another user - userid = 
50), I run into this problem the first time I use it:

--------------------
Sent Markup FEU:
file id: 0
user id: 50
rev: 0
type: Insert
start loc: 0
insert : a
---------------------
--------------------
Received Markup FEU:
file id: 0
user id: 50
rev: 85
type: Insert
start loc: 28
insert : a
---------------------
Editor Insertion-- fromPos: 28 string: a
org.eclipse.jface.text.BadLocationException

That exception is thrown because there is no location 28 in the editor.  I seem 
to get random numbers back.  All subsequent calls, it works fine but then they 
look like this:

--------------------
Sent Markup FEU:
file id: 0
user id: 4
rev: 86
type: Insert
start loc: 0
insert : a
---------------------
--------------------
Received Markup FEU:
file id: 0
user id: 4
rev: 87
type: Insert
start loc: 0
insert : a
---------------------

Which can print the character on the screen, except it's showing your own 
userid (in this case it was 4) instead of the userid of the fake client who 
sent the character (which was 50).  Checking the userid before its printed in 
the editor shows that the FEU correctly contains a userid of 50.

Also what's up with the revision numbers??

Original issue reported on code.google.com by rvmille...@gmail.com on 29 Mar 2011 at 1:43

GoogleCodeExporter commented 9 years ago
just to clarify, when you say you get random numbers back, you're talking about 
only the very first feu received?

in regards to your question, are you asking about why it jumped or why they're 
there in general?

Original comment by rharagut...@gmail.com on 29 Mar 2011 at 1:48

GoogleCodeExporter commented 9 years ago
(caution: this is my first time making a comment so I dont know where it will 
show up)

Yes, the received first FEU seems to have a bad start loc.

Yes, the first *sent* FEU seems to have a rev. number = 0.

Original comment by rvmille...@gmail.com on 29 Mar 2011 at 1:52

GoogleCodeExporter commented 9 years ago
Actually View Driver might just not be applicable anymore because it's using 
the same BackendClient to send from different users. And I'm guessing 
BackendClient was not designed for that.

Original comment by rvmille...@gmail.com on 29 Mar 2011 at 2:07

GoogleCodeExporter commented 9 years ago
I don't really understand what that means?

Original comment by rharagut...@gmail.com on 29 Mar 2011 at 2:09

GoogleCodeExporter commented 9 years ago
Like this might not be an issue.

It's something that used to work, but no longer does.

But I think that's because it's trying to do something the system wasn't 
designed to do anyway.  The best way to test is with two different clients.

Original comment by rvmille...@gmail.com on 29 Mar 2011 at 2:11

GoogleCodeExporter commented 9 years ago

Original comment by rvmille...@gmail.com on 29 Mar 2011 at 2:11

GoogleCodeExporter commented 9 years ago

Original comment by rharagut...@gmail.com on 30 Mar 2011 at 2:13