mirror of https://github.com/tuhiproject/tuhi.git
Workaround for Spark register problems
This is a workaround for registering problems with Spark. The registration hangs at "Connecting to device...". Internally the `GENERAL_ERROR` occurs, which is expected when registering a Spark device, but this should also raise an AuthorizeException, but it instead reaches the handler as DeviceError. It is currently unclear why the `GENERAL_ERROR` passes to this handler, so this catches any `GENERAL_ERROR` while registering a Spark device.pull/240/head
parent
820f168f43
commit
a0566e0dc0
|
@ -423,6 +423,13 @@ class WacomRegisterHelper(WacomProtocolLowLevelComm):
|
|||
except AuthorizationError:
|
||||
# this is expected
|
||||
pass
|
||||
except Exception as e:
|
||||
logger.exception('Got other Exception while registering Spark device')
|
||||
if e.errorcode == DeviceError.ErrorCode.GENERAL_ERROR:
|
||||
logger.debug('Got GENERAL_ERROR while registering Spark device')
|
||||
pass
|
||||
else:
|
||||
raise
|
||||
|
||||
# The "press button now command" on the spark
|
||||
self.p.execute(Interactions.REGISTER_PRESS_BUTTON)
|
||||
|
|
Loading…
Reference in New Issue