catch and log any linkage errors while enumerating hwws

This commit is contained in:
Craig Raw 2025-02-04 19:56:07 +02:00
parent d4c3c3afa8
commit 0305afbc02
3 changed files with 3 additions and 3 deletions

2
drongo

@ -1 +1 @@
Subproject commit 342c85a39e45c8e14c4b35f5188ecf93a6c826d6 Subproject commit ca758e128876470f673b5955d75d5311b47c6938

2
lark

@ -1 +1 @@
Subproject commit b379338cc270d32e4225cb67392fc7c3a7c91b85 Subproject commit b80cbbbc57939284cf270a7b450a0059d5f0ec15

View file

@ -54,7 +54,7 @@ public class Hwi {
Lark lark = getLark(passphrase); Lark lark = getLark(passphrase);
isPromptActive = true; isPromptActive = true;
return lark.enumerate().stream().map(Device::fromHardwareClient).toList(); return lark.enumerate().stream().map(Device::fromHardwareClient).toList();
} catch(Exception e) { } catch(Throwable e) {
log.error("Error enumerating USB devices", e); log.error("Error enumerating USB devices", e);
throw new ImportException("Error scanning" + (e.getMessage() == null || e.getMessage().isEmpty() ? ", check devices are ready" : ": " + e.getMessage()), e); throw new ImportException("Error scanning" + (e.getMessage() == null || e.getMessage().isEmpty() ? ", check devices are ready" : ": " + e.getMessage()), e);
} finally { } finally {