-
Notifications
You must be signed in to change notification settings - Fork 204
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
Inconsistent re-anchoring in multi-guest scenarios #3992
Comments
5 tasks
This is related to one of the sub-tasks in #3798, so I edited that issue's description to reference this one. The description in that issue mentions two different ways of fixing the problem in the VitalSource context:
This issue discusses the second solution, which we need to support multiple guests in the general context. In an ebook reader, the first would be sufficient. |
robertknight
added a commit
to robertknight/client
that referenced
this issue
Jan 12, 2022
When the sidebar is connected to multiple guest frames it will send all incoming annotations to all frames. The result is typically that the annotation will anchor in one frame and orphan in the others. Depending on what order this happens in, the annotation will non-deterministically show up as an Annotation or Orphan in the sidebar. In order to determine which frames an annotation should be sent to in all cases, we'd either need the backend to return information about which search URIs an annotation matches or make a separate search request for each frame and record the associated frame with the results. This will require some significant refactoring of the annotation search service. As an interim step, make `FrameSyncService` send annotations only to a single frame based on matching URL, with a fallback to sending to the main frame if there is no exact match. This will work as expected for most pages, and is at least deterministic when it does fail. When we have a solution for being able to match annotations to frames more generally, we can adapt this code to use it. This is a partial solution to hypothesis#3992.
robertknight
added a commit
that referenced
this issue
Jan 21, 2022
When the sidebar is connected to multiple guest frames it will send all incoming annotations to all frames. The result is typically that the annotation will anchor in one frame and orphan in the others. Depending on what order this happens in, the annotation will non-deterministically show up as an Annotation or Orphan in the sidebar. In order to determine which frames an annotation should be sent to in all cases, we'd either need the backend to return information about which search URIs an annotation matches or make a separate search request for each frame and record the associated frame with the results. This will require some significant refactoring of the annotation search service. As an interim step, make `FrameSyncService` send annotations only to a single frame based on matching URL, with a fallback to sending to the main frame if there is no exact match. This will work as expected for most pages, and is at least deterministic when it does fail. When we have a solution for being able to match annotations to frames more generally, we can adapt this code to use it. This is a partial solution to #3992.
This was referenced Jan 21, 2022
robertknight
added a commit
that referenced
this issue
Jan 26, 2022
When the sidebar is connected to multiple guest frames it will send all incoming annotations to all frames. The result is typically that the annotation will anchor in one frame and orphan in the others. Depending on what order this happens in, the annotation will non-deterministically show up as an Annotation or Orphan in the sidebar. In order to determine which frames an annotation should be sent to in all cases, we'd either need the backend to return information about which search URIs an annotation matches or make a separate search request for each frame and record the associated frame with the results. This will require some significant refactoring of the annotation search service. As an interim step, make `FrameSyncService` send annotations only to a single frame based on matching URL, with a fallback to sending to the main frame if there is no exact match. This will work as expected for most pages, and is at least deterministic when it does fail. When we have a solution for being able to match annotations to frames more generally, we can adapt this code to use it. This is a partial solution to #3992.
2 tasks
robertknight
added a commit
that referenced
this issue
Feb 1, 2022
When the sidebar is connected to multiple guest frames it will send all incoming annotations to all frames. The result is typically that the annotation will anchor in one frame and orphan in the others. Depending on what order this happens in, the annotation will non-deterministically show up as an Annotation or Orphan in the sidebar. In order to determine which frames an annotation should be sent to in all cases, we'd either need the backend to return information about which search URIs an annotation matches or make a separate search request for each frame and record the associated frame with the results. This will require some significant refactoring of the annotation search service. As an interim step, make `FrameSyncService` send annotations only to a single frame based on matching URL, with a fallback to sending to the main frame if there is no exact match. This will work as expected for most pages, and is at least deterministic when it does fail. When we have a solution for being able to match annotations to frames more generally, we can adapt this code to use it. This is a partial solution to #3992.
robertknight
added a commit
that referenced
this issue
Feb 2, 2022
When the sidebar is connected to multiple guest frames it will send all incoming annotations to all frames. The result is typically that the annotation will anchor in one frame and orphan in the others. Depending on what order this happens in, the annotation will non-deterministically show up as an Annotation or Orphan in the sidebar. In order to determine which frames an annotation should be sent to in all cases, we'd either need the backend to return information about which search URIs an annotation matches or make a separate search request for each frame and record the associated frame with the results. This will require some significant refactoring of the annotation search service. As an interim step, make `FrameSyncService` send annotations only to a single frame based on matching URL, with a fallback to sending to the main frame if there is no exact match. This will work as expected for most pages, and is at least deterministic when it does fail. When we have a solution for being able to match annotations to frames more generally, we can adapt this code to use it. This is a partial solution to #3992.
robertknight
added a commit
that referenced
this issue
Feb 2, 2022
When the sidebar is connected to multiple guest frames it will send all incoming annotations to all frames. The result is typically that the annotation will anchor in one frame and orphan in the others. Depending on what order this happens in, the annotation will non-deterministically show up as an Annotation or Orphan in the sidebar. In order to determine which frames an annotation should be sent to in all cases, we'd either need the backend to return information about which search URIs an annotation matches or make a separate search request for each frame and record the associated frame with the results. This will require some significant refactoring of the annotation search service. As an interim step, make `FrameSyncService` send annotations only to a single frame based on matching URL, with a fallback to sending to the main frame if there is no exact match. This will work as expected for most pages, and is at least deterministic when it does fail. When we have a solution for being able to match annotations to frames more generally, we can adapt this code to use it. This is a partial solution to #3992.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Re-anchoring of annotations is inconsistent when there are several
guest
frames. This is because thesidebar
send to all theguest
frames the annotations. Every frame tries to anchor the best it can, and depending of the timing of the reporting the annotation can be tagged asorphan
.Scenario 1 (re-anchored to several
guest
frames)Steps to reproduce
Expected behaviour
It should only be anchored to the frame where the annotation was made.
Actual behaviour
It appears on both frames
Browser/system information
All browsers
Screen.Recording.2021-12-03.at.17.51.19.mov
Scenario 2 (anchored correctly, reported as
orphan
)Steps to reproduce
Expected behaviour
It should only be anchored to the frame where the annotation was made, and it should be numbered in the
Annotations
tab.Actual behaviour
It sometimes appears on
Orphan
tab.Browser/system information
All browsers
Screen.Recording.2021-12-03.at.17.49.48.mov
The text was updated successfully, but these errors were encountered: