Table of Contents

Enum ErrorCode

Namespace
WebDriverBiDi
Assembly
WebDriverBiDi.dll

Enumeration of error codes that may be returned by the remote end of the WebDriver BiDi protocol in error responses to commands or in unsolicited error events. Each value is associated with the string value used in the JSON error responses.

[JsonConverter(typeof(EnumValueJsonConverter<ErrorCode>))]
[StringEnumUnmatchedValue<ErrorCode>(ErrorCode.UnsetErrorCode)]
public enum ErrorCode

Fields

[StringEnumValue("detached shadow root")] DetachedShadowRoot = 1

A command failed because the referenced shadow root is no longer attached to the DOM.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("element click intercepted")] ElementClickIntercepted = 2

The Element Click command could not be completed because the element receiving the events is obscuring the element that was requested clicked.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("element not interactable")] ElementNotInteractable = 3

A command could not be completed because the element is not pointer- or keyboard interactable.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("insecure certificate")] InsecureCertificate = 4

Navigation caused the user agent to hit a certificate warning, which is usually the result of an expired or invalid TLS certificate.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("invalid argument")] InvalidArgument = 5

An argument sent during a command was invalid or malformed.

[StringEnumValue("invalid cookie domain")] InvalidCookieDomain = 6

An illegal attempt was made to set a cookie under a different domain than the current page.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("invalid element state")] InvalidElementState = 7

A command could not be completed because the element is in an invalid state, e.g. attempting to clear an element that isn't both editable and resettable.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("invalid selector")] InvalidSelector = 8

An element command failed because an invalid selector was used.

[StringEnumValue("invalid session id")] InvalidSessionId = 9

The session ID used in the request was not valid.

[StringEnumValue("invalid web extension")] InvalidWebExtension = 10

The web extension data used in the command was not valid.

[StringEnumValue("javascript error")] JavascriptError = 11

An error occurred while executing JavaScript supplied by the user.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("move target out of bounds")] MoveTargetOutOfBounds = 12

The target for the pointer move action is not valid for the current view port.

[StringEnumValue("no such alert")] NoSuchAlert = 13

An attempt was made to operate on an alert that is not present.

[StringEnumValue("no such client window")] NoSuchClientWindow = 14

The ID of the client window was invalid when attempting to set the client window state.

[StringEnumValue("no such cookie")] NoSuchCookie = 15

No cookie matching the given path name was found amongst the associated cookies of session's current browsing context's active document.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("no such device")] NoSuchDevice = 16

No Bluetooth device matching the given device ID was found.

This error code comes from the Web Bluetooth specification.

[StringEnumValue("no such element")] NoSuchElement = 17

The target element for the command was not found.

[StringEnumValue("no such frame")] NoSuchFrame = 18

The target frame for the command was not found.

[StringEnumValue("no such handle")] NoSuchHandle = 19

The target handle for the command was not found.

[StringEnumValue("no such history entry")] NoSuchHistoryEntry = 20

The history entry for the command was not found.

[StringEnumValue("no such intercept")] NoSuchIntercept = 21

The ID of the network intercept used in the command was not valid.

[StringEnumValue("no such network collector")] NoSuchNetworkCollector = 22

The network data collector ID used in the command was not valid.

[StringEnumValue("no such network data")] NoSuchNetworkData = 23

The command referenced network data that is unknown: no data of the requested type was collected for the request, or none was collected by the specified collector.

[StringEnumValue("no such node")] NoSuchNode = 24

The node ID used in the command was not found.

[StringEnumValue("no such prompt")] NoSuchPrompt = 25

No prompt for a Bluetooth device matching the given prompt ID was found.

This error code comes from the Web Bluetooth specification.

[StringEnumValue("no such request")] NoSuchRequest = 26

The request ID for the network request used in the command was not found.

[StringEnumValue("no such screencast")] NoSuchScreencast = 27

The ID of the screencast used in the command was not found.

[StringEnumValue("no such script")] NoSuchScript = 28

The ID of the script used in the command was not found.

[StringEnumValue("no such shadow root")] NoSuchShadowRoot = 29

The element does not have a shadow root.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("no such storage partition")] NoSuchStoragePartition = 30

The storage partition used in the command was not found.

[StringEnumValue("no such user context")] NoSuchUserContext = 31

The ID of the user context used in the command was not found.

[StringEnumValue("no such web extension")] NoSuchWebExtension = 32

The ID of the web extension used in the command was not found.

[StringEnumValue("no such window")] NoSuchWindow = 33

A command to switch to a window could not be satisfied because the window could not be found.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("script timeout error")] ScriptTimeoutError = 34

A script did not complete before its timeout expired.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("session not created")] SessionNotCreated = 35

A new session could not be created successfully.

[StringEnumValue("stale element reference")] StaleElementReference = 36

A command failed because the referenced element is no longer attached to the DOM.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("timeout")] Timeout = 37

An operation did not complete before its timeout expired.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("unable to capture screen")] UnableToCaptureScreen = 38

The command was unable to capture the screenshot of the current browsing context.

[StringEnumValue("unable to close browser")] UnableToCloseBrowser = 39

The browser.close command was unable to close the browser, for example because other sessions are still active. The session that sent the command is ended regardless.

[StringEnumValue("unable to set cookie")] UnableToSetCookie = 40

The command was unable to set the cookie successfully.

[StringEnumValue("unable to set file input")] UnableToSetFileInput = 41

The command was unable to set the value of a file input element successfully.

[StringEnumValue("unavailable network data")] UnavailableNetworkData = 42

The command requested network data that is not available, because it was not collected or has already been evicted.

[StringEnumValue("underspecified storage partition")] UnderspecifiedStoragePartition = 43

The command was unable to perform the requested operation on the storage partition, because the parameters used to specify it were insufficient.

[StringEnumValue("unexpected alert open")] UnexpectedAlertOpen = 44

A modal dialog was open, blocking this operation.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

[StringEnumValue("unknown command")] UnknownCommand = 45

The command was not recognized by the remote end of the WebDriver BiDi protocol, and could not be processed.

[StringEnumValue("unknown error")] UnknownError = 46

The remote end of the WebDriver BiDi protocol returned an error that did not match any of the other defined error codes.

[StringEnumValue("unknown method")] UnknownMethod = 47

The requested command matched a known URL but did not match any method for that URL.

A WebDriver classic error code, not defined by the WebDriver BiDi specification. It is included because remote ends built on a classic WebDriver implementation have been observed to return it.

UnsetErrorCode = 0

Default value indicating that the error code was not set or did not match any known error code string.

[StringEnumValue("unsupported operation")] UnsupportedOperation = 48

The command is not supported by the remote end of the WebDriver BiDi protocol.

Remarks

Most values are the error codes the WebDriver BiDi protocol specification defines. The rest are WebDriver classic error codes, which the WebDriver BiDi specification does not define but which remote ends built on a classic WebDriver implementation have been observed to return; each of those says so in its own documentation. An error code string that matches no value is reported as UnsetErrorCode.