rokucommunity / roku-debug

A compatibility wrapper around the BrightScript debug protocol https://developer.roku.com/en-ca/docs/developer-program/debugging/socket-based-debugger.md
MIT License
12 stars 9 forks source link

Debug get stuck if the developer password authentication failed #175

Closed lvcabral closed 2 weeks ago

lvcabral commented 8 months ago

~~VS Code is not deploying or debugging unless the connection to port 8080 succeeds, and this port is not essential, as applications not using RSG would not need rendezvous tracking. Even disabling the option rendezvousTracking: false the connection to this port is being done. The extension debugger get stuck if 8080 is not open.~~

The actual reason it got stuck was because the developer password was wrong, so the 401 error (authentication) was returned, but no feedback for the user is given, and the debug sessions seems to be stuck with no updates on the device side.

TwitchBronBron commented 8 months ago

Just for reference, here's the logic: https://github.com/rokucommunity/roku-debug/blob/97c37c418fe7bc9d28925c7f7749ffa8286aac9c/src/RendezvousTracker.ts#L177

We should probably just add a Promise.race( with a 5000ms timeout, and then continue even if it times out.

Also, we should add an option to configure that port (for https://developer.roku.com/docs/developer-program/debugging/debugging-channels.md). Maybe call it sceneGraphDebugCommandsPort. it would default to 8080 but could be overridden.

TwitchBronBron commented 7 months ago

Thanks for updating the description. There's definitely a bug where, when the password is wrong, it just kinda silently fails or stalls out. We're going to work on showing a proper error message on bad password (403 http response).

TwitchBronBron commented 2 weeks ago

I think this has been fixed.