Shared-Reality-Lab / IMAGE-browser

IMAGE project browser extensions & client-side code
Other
2 stars 0 forks source link

"get IMAGE rendering" goes forever and does not pop anything up #144

Open jeffbl opened 2 years ago

jeffbl commented 2 years ago

I don't have a solid repro. case for this, but it has happened multiple times while reproducing Shared-Reality-Lab/IMAGE-server#187 and Shared-Reality-Lab/IMAGE-server#189.

Extension v0.1.0 from Chrome Web Store Brave Browser No screen reader active

Logging to server on assumption nothing is being returned, but @Clarisa1999 I'd imagine it could be a browser extension issue.

On the a photo, e.g.,

https://fr.wikipedia.org/wiki/Notre-Dame-de-Gr%C3%A2ce#/media/Fichier:Sreet_in_Montreal._Western_at_Prud'Homme_Ave_BAnQ_P48S1P03298.jpg

Right click-->IMAGE extension--> get IMAGE rendering

It typically gives the error in Shared-Reality-Lab/IMAGE-server#187, but after doing it for a while and getting renderings on other photos, it eventually stops returning anything. I ask for a rendering, and no window ever pops up with an error or with renderings. Restarting my browser fixes it, or going to another photo and getting a rendering then coming back to the one that wasn't working then gives an error as before.

Will add more here as I get more details, but wanted to put this on panel alpha list right away, since it is really hard to know whether it is working at all, or if you're just waiting for a rendering, when it sometimes fails like this.

Assigning to @jeffbl to add more details, @Clarisa1999 in case any guesses about a problem in the browser extension itself, and @JRegimbal in case you have hypotheses on this being a server issue.

I've looked at docker logs for orchestrator and traefik, and don't see anything weird there when this is happening. If it would be helpful to ping anyone when this is happening to take a closer look, message me.

jeffbl commented 2 years ago

Notes from further investigation:

@JRegimbal I'll let you comment on the theory the background script is getting disconnected?

JRegimbal commented 2 years ago

Yeah it seems like something is going wrong in communication between background script and port. Considering there's no error logged on the content side, I'm guessing it's probably that the information is not being sent to the tab/correct tab. It would make sense to add debugging information to both scripts however and see if we can get more information on how this is established and any changes in port storage, specifically the ports array in background.ts.

jeffbl commented 2 years ago

Since @Clarisa1999 got the previous extension issue, and is also working on the critical settings panel, I'm assigning to you, @jaydeepsingh25 .

Cybernide commented 2 years ago

I may have something similar here. First image on this page, it sometimes doesn't produce an error window or rendering https://www.adorama.com/alc/basic-landscape-photography-tips/ But it works properly and consistently if I open the image in a new tab: https://www.adorama.com/alc/wp-content/uploads/2018/11/landscape-photography-tips-yosemite-valley-feature.jpg

Wonder if it's something on the page, though. The IMAGE extension context menu doesn't show up for the remainder of the graphics on the page.

jeffbl commented 2 years ago

Both links are working fine for me in terms of getting renderings returned (although it is 0/2 in accuracy - it is not a hot spring, and I don't see a boat). If you can get any repro steps to trigger it, super helpful (but I've been unsuccessful).

The context menu not being present at all for the other images in the body of the article should be logged as a separate issue (I see the same behavior in Chrome on Linux)

jaydeepsingh25 commented 2 years ago

I have tried multiple times to reproduce the issue, but hard luck!! The other issue in which the context menu is not present for other images, is indeed there and is probably because there is syntax error in the HTML code of the page, but can be investigated further...

Cybernide commented 2 years ago

So if there's a pattern here, I can't quite figure it out because everything's working just fine today.

jeffbl commented 2 years ago

@Cybernide OK, so once Shared-Reality-Lab/IMAGE-server#33 is closed (minor) and the tutorial is done (Shared-Reality-Lab/auditory-haptic-graphics-browser#59) are you ok going with this as-is, and postponing further research on this item to restricted beta milestone?

@Cybernide Also, please don't forget to log the issue with the context menu not appearing at all.

Cybernide commented 2 years ago

Hold up, I'm having issues with the images now that they're on the test website. I'm investigating.

Cybernide commented 2 years ago

Unsure of what's going on, but yesterday I have no issues with the graphics on the webpage. Very confusing.

jaydeepsingh25 commented 2 years ago

Looks like there is uncertainty in the behaviour of extension, but we are unable to extract a pattern out of it. @jeffbl / @Cybernide , are you able to find any scenario where for the same image, sometime we get results and sometime there is no popup at all? I am unable to find any such scenario, although I do know there are various images for which there is no pop-up at all, but that is consistent and it is a different issue!!

jeffbl commented 2 years ago

image

Clarisa1999 commented 2 years ago

The error seems to occur when you move away from the tab/window with the image you want render and then you try to render the same image after some time without refreshing the page.

I used the picture of the Eiffel Tower to test this: https://www.planetware.com/pictures/france-f.htm

jeffbl commented 2 years ago

Thanks, @Clarisa1999 ! Did testing along those lines, on the assumption that it was some kind of timeout or something that might happen at a specific time. It happens very regulatly for me just leaving the tab and going to another, then coming back after a while. I've had it fail after around a 45s time away from the tab, but also had it work after 3 minutes. So it doesn't seem to be a specific amount of time, but from a bunch of runs, it seems to anecdotally happen more often with longer periods of time. Exact steps:

bring up tutorial page: https://image.a11y.mcgill.ca/pages/alph_tut.html switch to another tab wait a while switch back to tab right click the mountain/river photo & get image rendering EXPECT: reliably get a rendering ACTUAL: depending on time away from tab, may not return a rendering, with no activity in docker-compose logs output

@jaydeepsingh25 is this repro case solid enough to continue figuring this out?

jeffbl commented 2 years ago

anecdotally, while testing new extension build this morning, I seemed to be getting this really frequently, even when only leaving the tab for very brief (like ~10s) times. It is very confusing when you switch tabs, ask for a rendering, and nothing ever comes back.

jeffbl commented 2 years ago

Also note that the tutorial page linked above is now at its new location for beta: https://image.a11y.mcgill.ca/pages/tutorial.html

jeffbl commented 2 years ago

When this happens, I get this error in the extension page tile, and which I click the "Error" button I see this:

image

jeffbl commented 2 years ago

Transferred to browser since I think it is pretty clear this is a local browser issue....

jeffbl commented 2 years ago

With build directly from @jaydeepsingh25 from yesterday that is better instrumented, I cannot reproduce this bug in Chrome. Hypotheses:

I can, however, reproduce it in brave: image

jeffbl commented 2 years ago

I still cannot repro this on chrome Moving to CSUN milestone since it only appears to happen in Brave. We had others with this issue (e.g., Clarisa, confirming that was not in brave) If we get reports on this during beta, may have to prioritize it. Talking with @jaydeepsingh25 , he suspects this may happen in other browsers with some extensions installed. To be investigated.

The error seems to occur when you move away from the tab/window with the image you want render and then you try to render the same image after some time without refreshing the page.

I used the picture of the Eiffel Tower to test this: https://www.planetware.com/pictures/france-f.htm

@Clarisa1999 Can you confirm that you were using a browser other than Brave when you found this?

jeffbl commented 1 year ago

@jaydeepsingh25 I think we should close this since I haven't seen it in a long time. We can reactivate if this becomes an issue again?