core icon indicating copy to clipboard operation
core copied to clipboard

[network controller] Log when we fail to connect to a network

Open Gudahtt opened this issue 1 year ago • 1 comments

The lookupNetwork method of the network controller should include console warnings for all branches where we fail to connect to a network. This would be very useful when investigating bug reports.

Failing to connect to a network is in a class of errors that is expected, but still noteworthy and potentially related to a bug. Console warnings are a good solution for these situations; they provide hints in the console for anyone investigating, and they show up in Sentry if a real error is thrown in the vicinity of the warning.

Rather than using console.log directly, we should consider updating the controller to accept a loglevel instance, so that we can use that to print console warnings while leaving the client in full control of whether these logs are enabled or not.

Gudahtt avatar Jun 28 '23 13:06 Gudahtt

Status is not enough. It just says "unavailable" but we don't know why. We'd like to know why. Arguably it is already correct but it might be useful to expose the actual error.

desi avatar May 01 '24 15:05 desi