-
I guess it's possible that something about your connection means the messages take more that a second to arrive??
That's probably it! I'm using LTE 5G data plan and don't typically use wi-fi when not at home. I just tried at home with wifi and it works. I turned off wifi on the phone and it stopped working from the same computer, now I have the same "No activity on connection" message over 5G.
I tried to disable data saving quick toggle on the phone but it did not help.
Maybe it is not just the speed as with wifi both devices are on the same network so they may even find direct path over local network avoiding NAT/firewalls, but still increasing the timeout might help since I get that blue/violet connected message on the phone.
The offending code is at https://github.com/espruino/EspruinoTools/blob/d809a2bacbe609edb189b82bcfb7782a4cd277c2/libs/webrtc-connection.js#L328
There's a bit of documentation about what's meant to happen at the head of that file.
... but the
[WebRTC] No activity on connection - closing 79543ed0-aa61-435f-ac9a-38ac3d01ac00
message is exactly what I get on mine when I have the wrong UUID or the App Loader relay isn't running on the phone I'm connected to.As I understand it with Peerjs you basically open a connection and it's a bit like going into a chatroom. The connection opens, but there may not be anyone there.
The IDE connects using that UUID (the Phone is supposed to be the host) and it keeps sending
ping
messages once a second, but it it doesn't get any response in a second it times out.I guess it's possible that something about your connection means the messages take more that a second to arrive??