Since I don't know web extension code, I have a question. When setting `content_scripts` property, where is this script loaed in gecko's code? I should debug web extension code internally for GeckoView.
Also of course, `"run_at": "document_end"` resolves this issue since content script is loaded after switching process.
This log is example when this occurs. pageshow is fired, but content scripts doesn't receive it. I suspect GeckoView's web extensions implementation if this doesn't occur on Desktop.
```
09-19 14:40:57.468 7681 7696 I Isolated Web Content: loading test-support.js
...
09-19 14:40:57.529 7547 7566 D GeckoViewXUL: WillChangeBrowserRemoteness
09-19 14:40:57.530 7547 7566 D GeckoViewMediaControl: onDestroyBrowser
09-19 14:40:57.531 7681 7696 I Isolated Web Content: pagehide on test-support.js
09-19 14:40:57.531 7681 7696 E Isolated Web Content: [JavaScript Error: "TypeError: can't access property "disconnect", backgroundPort is null" {file: "moz-extension://ea2bd5a4-08f2-4bcf-a708-d3a7a2302198/test-support.js" line: 57}]
09-19 14:40:57.531 7681 7696 E Isolated Web Content: @moz-extension://ea2bd5a4-08f2-4bcf-a708-d3a7a2302198/test-support.js:57:3
09-19 14:40:57.532 7681 7696 D GeckoViewSelectionActionDelegate[C]: handleEvent: visibilitychange
09-19 14:40:57.532 7681 7696 D GeckoViewClipboardPermissionChild[C]: handleEvent: pagehide
09-19 14:40:57.533 7681 7696 D GeckoViewAutoFill[C]: handleEvent: pagehide
...
09-19 14:40:57.542 7547 7566 D GeckoViewXUL: receiveMessage GeckoView:ContentModuleLoaded {}
09-19 14:40:57.545 7547 7566 E GeckoConsole: [JavaScript Error: "HTTPS-Only Mode: Upgrading insecure request “https://expired.example.com/” failed. (M21-C8181)"]
09-19 14:40:57.547 7681 7696 D GeckoViewContent[C]: handleEvent: pageshow
09-19 14:40:57.547 7681 7696 D GeckoViewProgressDelegate[C]: handleEvent: pageshow
09-19 14:40:57.548 7681 7696 D GeckoViewAutoFill[C]: handleEvent: pageshow
09-19 14:40:57.549 7547 7566 D GeckoViewProgress: receiveMessage: pageshow
```
Bug 1673954 Comment 10 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
Since I don't know web extension code, I have a question. When setting `content_scripts` property, where is this script loaed in gecko's code? I should debug web extension code internally for GeckoView.
Also of course, `"run_at": "document_end"` resolves this issue since content script is loaded after switching process.
This log is example when this occurs. pageshow is fired, but content scripts doesn't receive it. I suspect GeckoView's web extensions implementation if this doesn't occur on Desktop.
```
09-19 14:40:57.468 7681 7696 I Isolated Web Content: loading test-support.js
...
09-19 14:40:57.529 7547 7566 D GeckoViewXUL: WillChangeBrowserRemoteness
09-19 14:40:57.530 7547 7566 D GeckoViewMediaControl: onDestroyBrowser
09-19 14:40:57.531 7681 7696 I Isolated Web Content: pagehide on test-support.js
09-19 14:40:57.531 7681 7696 E Isolated Web Content: [JavaScript Error: "TypeError: can't access property "disconnect", backgroundPort is null" {file: "moz-extension://ea2bd5a4-08f2-4bcf-a708-d3a7a2302198/test-support.js" line: 57}]
09-19 14:40:57.531 7681 7696 E Isolated Web Content: @moz-extension://ea2bd5a4-08f2-4bcf-a708-d3a7a2302198/test-support.js:57:3
09-19 14:40:57.532 7681 7696 D GeckoViewSelectionActionDelegate[C]: handleEvent: visibilitychange
09-19 14:40:57.532 7681 7696 D GeckoViewClipboardPermissionChild[C]: handleEvent: pagehide
09-19 14:40:57.533 7681 7696 D GeckoViewAutoFill[C]: handleEvent: pagehide
...
09-19 14:40:57.535 7547 7566 D GeckoViewXUL: DidChangeBrowserRemoteness
09-19 14:40:57.536 7547 7566 D GeckoViewNavigation: sessionContextId=null
09-19 14:40:57.536 7547 7566 D GeckoViewMediaControl: onInitBrowser
...
09-19 14:40:57.542 7547 7566 D GeckoViewXUL: receiveMessage GeckoView:ContentModuleLoaded {}
...
09-19 14:40:57.545 7547 7566 E GeckoConsole: [JavaScript Error: "HTTPS-Only Mode: Upgrading insecure request “https://expired.example.com/” failed. (M21-C8181)"]
09-19 14:40:57.547 7681 7696 D GeckoViewContent[C]: handleEvent: pageshow
09-19 14:40:57.547 7681 7696 D GeckoViewProgressDelegate[C]: handleEvent: pageshow
09-19 14:40:57.548 7681 7696 D GeckoViewAutoFill[C]: handleEvent: pageshow
09-19 14:40:57.549 7547 7566 D GeckoViewProgress: receiveMessage: pageshow
```
Since I don't know web extension code, I have a question. When setting `content_scripts` property, where is this script loaed in gecko's code? I should debug web extension code internally for GeckoView.
This log is example when this occurs. pageshow is fired, but content scripts doesn't receive it. I suspect GeckoView's web extensions implementation if this doesn't occur on Desktop.
```
09-19 14:40:57.468 7681 7696 I Isolated Web Content: loading test-support.js
...
09-19 14:40:57.529 7547 7566 D GeckoViewXUL: WillChangeBrowserRemoteness
09-19 14:40:57.530 7547 7566 D GeckoViewMediaControl: onDestroyBrowser
09-19 14:40:57.531 7681 7696 I Isolated Web Content: pagehide on test-support.js
09-19 14:40:57.531 7681 7696 E Isolated Web Content: [JavaScript Error: "TypeError: can't access property "disconnect", backgroundPort is null" {file: "moz-extension://ea2bd5a4-08f2-4bcf-a708-d3a7a2302198/test-support.js" line: 57}]
09-19 14:40:57.531 7681 7696 E Isolated Web Content: @moz-extension://ea2bd5a4-08f2-4bcf-a708-d3a7a2302198/test-support.js:57:3
09-19 14:40:57.532 7681 7696 D GeckoViewSelectionActionDelegate[C]: handleEvent: visibilitychange
09-19 14:40:57.532 7681 7696 D GeckoViewClipboardPermissionChild[C]: handleEvent: pagehide
09-19 14:40:57.533 7681 7696 D GeckoViewAutoFill[C]: handleEvent: pagehide
...
09-19 14:40:57.535 7547 7566 D GeckoViewXUL: DidChangeBrowserRemoteness
09-19 14:40:57.536 7547 7566 D GeckoViewNavigation: sessionContextId=null
09-19 14:40:57.536 7547 7566 D GeckoViewMediaControl: onInitBrowser
...
09-19 14:40:57.542 7547 7566 D GeckoViewXUL: receiveMessage GeckoView:ContentModuleLoaded {}
...
09-19 14:40:57.545 7547 7566 E GeckoConsole: [JavaScript Error: "HTTPS-Only Mode: Upgrading insecure request “https://expired.example.com/” failed. (M21-C8181)"]
09-19 14:40:57.547 7681 7696 D GeckoViewContent[C]: handleEvent: pageshow
09-19 14:40:57.547 7681 7696 D GeckoViewProgressDelegate[C]: handleEvent: pageshow
09-19 14:40:57.548 7681 7696 D GeckoViewAutoFill[C]: handleEvent: pageshow
09-19 14:40:57.549 7547 7566 D GeckoViewProgress: receiveMessage: pageshow
```