You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to access the archive of the current tab when the website isn't loading, I receive the error notification stating "The page url is not valid". This mostly happens when trying to load a website that is experiencing an unexpected increase in traffic and is likely not returning a response.
Step 1. Try to access a website that is not loading.
Step 2. Click the extension icon in the tool bar. Make sure "Tab" is selected vs "URL"
Step 3. Click one of the engines, e.g. "Wayback Machine" or "Google".
Step 4. Receive error notification "The page url is not valid".
Debugging
I did some light debugging of the code to try to understand why this happens.
The relevant code appears to be in onActionPopupClick
By logging the values of docUrl and tab.url in the function i get empty string for docUrl and "about:blank" for tab.url.
Meaning that OnActionClick will be passed "about:blank"
So basically I expected the string in the address bar to be passed to the extension, but rather the url of the previously loaded page appears to be passed.
To fix this I guess it could be changed so that the url in the address bar could be passed.
However that may break user's existing expectations in other contexts.
Should the code just stay as is and the user be expected to enter the url in the extension when the page isn't loading?
Any ideas on how to approach fixing this?
The text was updated successfully, but these errors were encountered:
System
Bug description
When trying to access the archive of the current tab when the website isn't loading, I receive the error notification stating "The page url is not valid". This mostly happens when trying to load a website that is experiencing an unexpected increase in traffic and is likely not returning a response.
Step 1. Try to access a website that is not loading.
Step 2. Click the extension icon in the tool bar. Make sure "Tab" is selected vs "URL"
Step 3. Click one of the engines, e.g. "Wayback Machine" or "Google".
Step 4. Receive error notification "The page url is not valid".
Debugging
I did some light debugging of the code to try to understand why this happens.
The relevant code appears to be in onActionPopupClick
web-archives/src/background/main.js
Line 762 in eb7bbdd
By logging the values of docUrl and tab.url in the function i get empty string for docUrl and "about:blank" for tab.url.
Meaning that OnActionClick will be passed "about:blank"
web-archives/src/background/main.js
Line 772 in eb7bbdd
Eventually searchDocument will be passed "about:blank"
web-archives/src/background/main.js
Line 466 in eb7bbdd
Where it will call validateUrl on the string. Since "about:blank" isn't a valid url with http https or ftp protocols used, it shows the
notification.
web-archives/src/background/main.js
Line 468 in eb7bbdd
How to Fix
So basically I expected the string in the address bar to be passed to the extension, but rather the url of the previously loaded page appears to be passed.
To fix this I guess it could be changed so that the url in the address bar could be passed.
However that may break user's existing expectations in other contexts.
Should the code just stay as is and the user be expected to enter the url in the extension when the page isn't loading?
Any ideas on how to approach fixing this?
The text was updated successfully, but these errors were encountered: