Hi.
In my temporary loaded web extension to FF I have the following piece of the code (after calling connectNative)
port.onDisconnect.addListener((p) => {
if(p.error)
console.log(`Native port disconnected due to an error: ${p.error.message}`);
else
console.log("native port -disconnected");
});
logging on browser console gives the following
native port -disconnected
So there is no error, and no part of NativeHost or webExtension calls port.disconnect()
How to find the reason for disconnection? Documentation talking about destroying page that created connection, but this background script doesn't belong any page and loaded on web Ext injection and stays all the time.
Please advise how to debug?
how to find a reason for runtime.Port (native) disconnect
-
- Posts: 2
- Joined: April 20th, 2021, 12:53 pm
- DanRaisch
- Moderator
- Posts: 127246
- Joined: September 23rd, 2004, 8:57 pm
- Location: Somewhere on the right coast
Re: how to find a reason for runtime.Port (native) disconne
Moving to Extension Development.