pavlobu / deskreen

Deskreen turns any device with a web browser into a secondary screen for your computer. ⭐️ Star to support our work!
https://deskreen.com
GNU Affero General Public License v3.0
16.89k stars 908 forks source link

No WiFi and LAN connection when using NordVPN #169

Open GanerCodes opened 2 years ago

GanerCodes commented 2 years ago

Local network access and everything is enabled in Nord, I even tried limiting it to only run with certain applications however it doesn't fix this. Funny thing is I can still connect to the IP on my phone/pc/etc, just the prompt is blocking me from doing anything image

gerroon commented 2 years ago

I have this issue as well, but I do not use NordVPN. I have my own Wireguard server, and I have LAN. This is a Windows 10 PC.

Does this app need access to Internet to function?

It seems like it is checking for update and fails then decides no network is available?

18:47:01.832 > Checking for update
(node:6064) electron: The default of contextIsolation is deprecated and will be changing from false to true in a future release of Electron.  See https://github.com/electron/electron/issues/23506 for more information
18:47:01.864 > Error: Error: net::ERR_NAME_NOT_RESOLVED
    at SimpleURLLoaderWrapper.<anonymous> (electron/js2c/browser_init.js:105:6497)
    at SimpleURLLoaderWrapper.emit (events.js:315:20)
(node:6064) UnhandledPromiseRejectionWarning: Error: net::ERR_NAME_NOT_RESOLVED
    at SimpleURLLoaderWrapper.<anonymous> (electron/js2c/browser_init.js:105:6497)
    at SimpleURLLoaderWrapper.emit (events.js:315:20)
ferrlen commented 2 years ago

@GanerCodes if Deskreen is working for you and the only issue is that the "No Wifi" prompt is in the way, you can remove that prompt through somewhat of a hack, opening the Electron webdev tools.

Here's how to do it:

  1. start Deskreen with the --remote-debugging-port flag
  2. look in the CLI what's the port that Deskreen is using (it should presented in the first lines, http://127.0.0.1:, the port is the next number.
  3. Open a webbrowser in your host computer and go to http://127.0.0.1:yourporthere and click on the "inspector" link.
  4. Now open the webdev tools (Ctrl+Shift+K in Firefox, Ctrl+Shift+I in Chrome) and find the element there to be deleted. It's probably the last div there, you can search for it with something like:
for (let div of document.getElementsByTagName('div')) {
  if (div.textContent.includes('No WiFi or LAN')) console.log(div);
}

PS: this is a horrible hack, but it can be a work around while this issue isn't fixed