-
Notifications
You must be signed in to change notification settings - Fork 4
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
Hypothesis LMS app saving annotations on URL with a Hypothesis-made URL parameter #438
Comments
Additional note: some screenshots from the user's students show that at one point the students could see each others' annotations. It looks like this is document_id = 1985147, and it looks like the URL with the parameters is equivalent to the URL without parameters. It looks like a similar problem happened with doc 2005153 and several other docs. |
I think I know what's happening here, but not why, or what to do about it yet. In order for document equivalence to work, we insert: <link rel="canonical" href="https://www.ascd.org/el/articles/6-intrinsic-motivators-to-power-up-your-teaching"> But the original page inserts one as well: <link rel="canonical" href="http://localhost:9085/proxy/mp_/https://www.ascd.org/el/articles/6-intrinsic-motivators-to-power-up-your-teaching?via.client.ignoreOtherConfiguration=1&via.client.openSidebar=1&via.external_link_mode=new-tab&via.client.requestConfigFromFrame.origin=http%3A%2F%2Flocalhost%3A8001&via.client.requestConfigFromFrame.ancestorLevel=2&via.blocked_for=lms"> I don't know exactly how this is happening. One guess is it's dynamically reading the location and putting it in? I don't think we are doing this, but I can check. I suspect what's happening is the last canonical declaration "wins" and ends up being the one all the annotations are added to. |
I've added a POC PR to show how we can interact with the canonical values declared by pages. This PR completely destroys it, and this causes all annotations to re-appear. I don't think this is necessarily the best way to go though. |
I think this is fixed now? It's a bit hard to say as from the UK there are two separate Cookie popups that render the page mostly un-usable. |
Hmm, I'm not so sure. I'm still seeing broken canonical values... edit: A bit more detail here. The backend is writing the canonical URL correctly, but something is rewriting it back to the original location (in Via). A few options were discussed, but a potential "fix" which is easy to do is to completely destroy the tag when rewriting the page. We can delete all attributes from it (although we can't get rid of it completely). This would result in an empty On the other hand this is totally broken right now, so this seems like we could put it in as an interim fix. |
It seems like assignments made for: End up with: You can see the full URL there in the client help info. This seems to have the canonical URL back as well: |
Testing this again here: https://hypothesis.instructure.com/courses/359/assignments/7732
Document id = 1985147. This no longer appears to be a document equivalence issue, we're still saving the URL incorrectly. |
Bug report form
Steps to reproduce
https://www.ascd.org/el/articles/6-intrinsic-motivators-to-power-up-your-teaching?via.client.ignoreOtherConfiguration=1&via.client.openSidebar=1&via.external_link_mode=new-tab&via.client.requestConfigFromFrame.origin=https%3A%2F%2Flms.hypothes.is&via.client.requestConfigFromFrame.ancestorLevel=2&via.blocked_for=lms
Notes:
Example:
https://hypothesis.instructure.com/courses/266/assignments/2811
Expected behaviour
Annotations should save to the URL without the parameter
Browser/system information
Chrome 98
MacOC 11.6
Possible duplicates?
The text was updated successfully, but these errors were encountered: