feat: make ErrorType enums compare as strings (#269)
The DBusError exception stores the error type as string. This makes the exception not directly compare to the ErrorType members (for example DBusError(ErrorType.FAILED, "").type != ErrorType.FAILED). This makes ErrorType also a string to make this comparision work.
This commit is contained in:
@@ -91,7 +91,7 @@ class ArgDirection(Enum):
|
||||
OUT = "out"
|
||||
|
||||
|
||||
class ErrorType(Enum):
|
||||
class ErrorType(str, Enum):
|
||||
"""An enum for the type of an error for a message reply.
|
||||
|
||||
:seealso: http://man7.org/linux/man-pages/man3/sd-bus-errors.3.html
|
||||
|
||||
Reference in New Issue
Block a user