Project

General

Profile

Actions

Bug #747

closed

Website favorite icons aren't updated when navigating history

Added by Soren Stoutner over 3 years ago. Updated 10 months ago.

Status:
Closed
Priority:
Next Release
Start date:
07/21/2021
Due date:
% Done:

0%

Estimated time:

Description

We had this problem several years ago and it was fixed, but it has recently started happening again. I am not sure what has changed. Perhaps it relates to the same WebView changes that are preventing domain font sizes from working properly.

https://redmine.stoutner.com/issues/739


Files

Wrong Favorite Icon.png (116 KB) Wrong Favorite Icon.png Soren Stoutner, 10/27/2023 01:33 PM
Actions #1

Updated by Soren Stoutner over 3 years ago

This appears to only happen when a URL is loaded from a link in a website. To replicate, do a search for `Don't kill my app` and then click on the link to dontkillmyapp.com.

Actions #2

Updated by Soren Stoutner about 2 years ago

There is some additional information at #946.

Actions #3

Updated by Soren Stoutner about 2 years ago

This bug is intermittent, which means it probably relates to some sort of race condition.

Actions #4

Updated by Soren Stoutner about 2 years ago

  • Subject changed from When a website has no favorite icon, the favorite icon of the previous website is displayed to When a website has no favorite icon, the favorite icon of the previous website is sometimes displayed
Actions #5

Updated by Soren Stoutner about 2 years ago

The problem is caused because favorite icon requests are asynchronous. They are often (or perhaps always) not returned (or maybe even made) until after the webpage "finishes" loading. Sometimes, they can be significantly delayed.

If a website with a favorite icon is loaded and then another website without a favorite icon is loaded the favorite icon for the first website might be returned after the WebView has moved on to the second website. `onReceivedIcon` does not provide any mechanism to determine which URL requested the icon.

https://developer.android.com/reference/android/webkit/WebChromeClient#onReceivedIcon(android.webkit.WebView,%20android.graphics.Bitmap)

In the past, I was able to work around this a bit by discarding any icons received while a website is loading, as these will be from previous websites. However, sometimes a favorite icon is so delayed that it doesn't load until after the second website has finished loading, which leads to this bug.

There isn't really anything I can do to work around this in Privacy Browser, but I will submit an upstream bug to the Chromium project and see if they will address it there.

Actions #7

Updated by Soren Stoutner about 2 years ago

  • Status changed from New to In Progress
Actions #8

Updated by Soren Stoutner about 1 year ago

This can happen when navigating the history. For example, load https://mwmbl.org, which has no favorite icon. Click on the Github link, which will load the Github favorite icon. Go back to mwmble.org, which will still display the Github icon.

Actions #9

Updated by Soren Stoutner about 1 year ago

  • Priority changed from Next Release to 3.x
Actions #10

Updated by Soren Stoutner about 1 year ago

  • Status changed from In Progress to New
  • Priority changed from 3.x to Next Release

Something similar happens when viewing https://www.mojeek.com/news.

Actions #11

Updated by Soren Stoutner about 1 year ago

  • Subject changed from When a website has no favorite icon, the favorite icon of the previous website is sometimes displayed to Website favorite icons aren't updated when navigating history
Actions #14

Updated by Soren Stoutner 10 months ago

That sounds like a different issue. You should create a separate bug report with a list of steps to reproduce the behavior.

Actions

Also available in: Atom PDF