Exceptions

Exception is raised whenever a certain operation is terminated abnormally. Besides python Built-in Exceptions, we also define clicknium exceptions which all inherit from BaseError.

Clicknium Exceptions #

ExceptionDescription
BaseErrorAll Clicknium exceptions inherit from this class.
ArgumentErrorArgumentError is raised when at least one of the arguments provided to a method is not valid.
ArgumentNullErrorArgumentNullError is raised when a null reference is passed to a method that does not accept it as a valid argument.
ArgumentOutOfRangeErrorArgumentOutOfRangeError is raised when the value of an argument is out of the allowable range of values as defined by the invoked method.
BrowserNotInstallErrorBrowserNotInstallError is raised when the specified browser is not installed.
BrowserNotRunErrorBrowserNotRunError is raised when the specified browser is not running.
ElementNotFoundErrorElementNotFoundError is raised when the target UI element can not be found by the given locator.
ExtensionOperationErrorExtensionOperationError is raised when an extension fails in operation “install”, “update” or “uninstall”.
InvalidOperationErrorInvalidOperationError is raised when a method call is invalid for the object’s current state.
InvalidSelectedItemErrorInvalidSelectedItemError is raised when the item to be selected is invalid for the object’s current state.
LocatorRequestErrorLocatorRequestError is raised when the cloud locator cannot be acquired due to server request error.
LocatorUndefinedErrorLocatorUndefinedError is raised when the specified locator can not be found in locator store.
NotSupportedErrorNotSupportedError is raised when an invoked method is not supported, or when an attempt to read, seek, or write to a stream that does not support the invoked functionality.
NotSupportedOperationErrorNotSupportedOperationError is raised when the method is invoked by a UI element which does not support the type of operation.
NotSupportedOperationOptionErrorNotSupportedOperationOptionError is raised when the specified option value is not supported by the target UI element.
OperationTimeoutErrorOperationTimeoutError is raised when a certain operation is not completed within given time.
ProjectSettingNotFoundErrorProjectSettingNotFoundError is raised when project setting file clicknium.yaml is missing.
ScreenOperationErrorScreenOperationError is raised when screen operations of Windows desktop UI element fail.
UiaPatternNotFoundErrorUiaPatternNotFoundError is raised when a window UI element can not be found by UIA technology.
UnAuthorizedErrorUnAuthorizedError is raised when user does not sign in or the sign in state is expired.
UnreachableBrowserExtensionErrorUnreachableBrowserExtensionError is raised when the specified browser’s extension is not in ready state. Please check if the extension is installed and enabled.
WebElementNotRespondingErrorWebElementNotRespondingError is raised when the web page is not responding.
WebErrorWebError is raised for common web automation exceptions.
WindowErrorWindowError is raised for common window exceptions.
WindowsNativeErrorWindowsNativeError is raised when an underneath win32 method fails.
What are your feelings
Table of contents
Updated on 30 August 2023