Error Codes
The UTAM compiler generates Java or JavaScript page objects from source JSON page objects. If the compiler encounters an error in a JSON page object, it emits an error code and an error message.
To combine all compilation errors into one report and throw an error at the end, set the interruptCompilerOnError
option to false
in the compiler configuration file. For information about the compiler configuration options, see:
Here's the list of error codes.
Error Code 7
This property isn't supported. For a list of supported page object properties, see the JSON Grammar.
Incorrect JSON example:
{
"methods": [
{
"name": "testNestedArgs",
"compose": [
{
"element": "self",
"apply": "unknownMethod",
"args": [
{
"value": "string",
"args": [
{
"value": "not allowed"
}
]
}
]
}
]
}
]
}
Error message:
error 7: method "testNestedArgs" statement "unknownMethod": property "args" is not supported
Error Code 8
This property isn't supported. The set of supported properties is listed in the error message.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": { "css": "css" },
"type": "frame",
"nullable": true
}
]
}
Error message:
error 8: element "test": property "nullable" is not supported, supported are: name, public, selector, type
Error Code 9
A required property is missing.
Incorrect JSON example:
{
"elements": [
{
"name": "test"
}
]
}
Error message:
error 9: element "test": property "selector" is required
Error Code 10
This property isn't supported. An alternative property is suggested in the error message.
Incorrect JSON example:
{
"description": ""
}
Error message:
error 10: page object description: property "text" should be a non-empty string, instead found empty
Error Code 11
This array can't contain a member with an empty string.
Incorrect JSON example:
{
"profile": [
{
"name": [1]
}
]
}
Error message:
error 11: profile "name": array member should be a non-empty string, instead found number
Error Code 12
This property must be set to a non-empty array.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": []
}
]
}
]
}
Error message:
error 12: method "test": property "args" should be a not empty array
Error Code 13
This object can't be empty.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [true]
}
]
}
Error message:
error 13: method "test": compose statement should be a non-empty object
Error Code 100
The arguments are incorrectly formatted. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"value": true,
"type": "string"
}
]
}
]
}
]
}
Error message:
error 100: method "test" arguments: incorrect argument format
Error Code 101
An unknown element is referenced as an argument. Check that the elementReference
in the args
array corresponds to a defined element.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"value": "argName",
"type": "elementReference"
}
]
}
]
}
]
}
Error message:
error 101: method "test" arguments: unknown element with name "argName" is referenced
Error Code 102
An argument is using an unsupported literal argument type. This example uses a number (1.024) but only integers are supported. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"value": 1.024
}
]
}
]
}
]
}
Error message:
error 102: method "test" arguments: unsupported literal argument type "1.024"
Error Code 103
An argument is using an unsupported argument type. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"type": "elementReference"
}
]
}
]
}
]
}
Error message:
error 103: method "test" arguments: unsupported argument type "elementReference"
Error Code 104
A function argument type requires a predicate
property and it's missing or incorrectly formatted. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"name": "name",
"type": "function"
}
]
}
]
}
]
}
Error message:
error 104: method "test" arguments: incorrect predicate format
Error Code 105
Literal arguments aren't allowed in this context. Use a name
property instead of a value
property. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"args": [
{
"value": "string literal"
}
],
"compose": [
{
"element": "root"
}
]
}
]
}
Error message:
error 105: method "test" arguments: literal arguments are not allowed
Error Code 106
An argument is using an incorrect elementReference
format. See Element Reference.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"value": "myElement",
"type": "elementReference",
"predicate": []
}
]
}
]
}
]
}
Error message:
error 106: method "test" arguments: incorrect format of elementReference argument
Error Code 107
A duplicate argument name is defined. Look for duplicate argument names.
Incorrect JSON example:
{
"elements": [
{
"name": "element",
"selector": {
"css": "selector %s",
"returnAll": true,
"args": [
{
"name": "arg1",
"type": "string"
}
]
},
"filter": {
"apply": "getAttribute",
"args": [
{
"name": "arg1",
"type": "string"
}
],
"matcher": {
"type": "stringContains",
"args": [
{
"name": "arg1",
"type": "string"
}
]
}
}
}
]
}
Error message:
error 107: element "element" arguments: argument with name "arg1" is already declared
Error Code 108
There's a mismatch in the expected number of arguments.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "selector",
"returnAll": true
},
"type": "my/page/object",
"filter": {
"apply": "getText",
"matcher": {
"type": "isTrue",
"args": [
{
"name": "arg",
"type": "string"
}
]
}
}
}
]
}
Error message:
error 108: element "test" filter matcher arguments: expected number of arguments is 0, found 1
Error Code 109
An argument has an incorrect type. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"apply": "waitFor",
"args": [
{
"type": "function",
"predicate": [
{
"element": "root",
"apply": "isPresent"
}
]
},
{
"value": true
}
]
}
]
}
]
}
Error message:
error 109: method "test" arguments: argument "true" has incorrect type, expected "literal string", found "Boolean"
Error Code 110
A selector has an unknown parameter type. See Selector Parameters.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"public": true,
"selector": {
"css": "str[%f]",
"args": [
{
"name": "num",
"type": "number"
}
]
}
}
]
}
Error message:
error 110: element "test" selector arguments: unknown selector parameter type "%f", only string and number are supported
Error Code 111
An argument can only define either a "name" or "value" property. See Supported Argument Types. Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [{ "value": "true", "name": "name" }]
}
]
}
]
}
Error message:
error 111: method "test" arguments: either "name" or "value" is supported for an argument, not both
Error Code 112
An argument with a "name" property also requires a "type" property. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"name": "name"
}
]
}
]
}
]
}
Error message:
error 112: method "test" arguments: "type" is required for an argument "name"
Error Code 113
An argument must have either a "name" or "value" property. See Supported Argument Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "world",
"apply": "setText",
"args": [
{
"type": "string"
}
]
}
]
}
]
}
Error message:
error 113: method "test" arguments: either "name" or "value" is required for an argument
Error Code 114
A literal or function argument doesn't support a description
property.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"apply": "waitFor",
"args": [
{
"type": "function",
"description": "redundant",
"predicate": [
{
"element": "root"
}
]
}
]
}
]
}
]
}
Error message:
error 114: method "test" arguments: property "description" is not supported for literal or function argument
Error Code 115
An invalid basic element type is defined. See Basic Element.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"type": ["wrong"],
"selector": {
"css": "css"
}
}
]
}
Error message:
error 115: element "test" type: basic type "wrong" is not supported, valid values are: actionable, clickable, draggable, editable, touchable
Error Code 116
A duplicate basic type is defined.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"type": ["clickable", "clickable"],
"selector": {
"css": "css"
}
}
]
}
Error message:
error 116: element "test" type: duplicate basic type "clickable", basic type values must be unique
Error Code 200
An element is incorrectly formatted. See Basic Element.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"wrong": "test",
"type": "container"
}
]
}
Error message:
error 200: root elements: incorrect format of elements
Error Code 201
An incorrect element type is defined. A custom type must contain alphanumeric characters only with the schema [package-name]/[custom/path]/pageObject
.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"type": "wrong",
"selector": {
"css": "css"
}
}
]
}
Error message:
error 201: element "test": type "wrong" is not supported, valid values are: custom, container, frame, actionable, clickable, draggable, editable, touchable
Error Code 202
A duplicate element with the same name is defined.
Incorrect JSON example:
{
"elements": [
{
"name": "dupElement",
"selector": {
"css": "css"
}
},
{
"name": "dupElement",
"selector": {
"css": "css"
}
}
]
}
Error message:
error 202: element "dupElement": element with same name was already declared
Error Code 203
An element marked as a list can't have nested elements or a shadow root. See List and Index.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "css",
"returnAll": true
},
"elements": [
{
"name": "nested",
"selector": {
"css": "css"
}
}
]
}
]
}
Error message:
error 203: element "test": element marked as a list cannot have nested elements or shadow root
Error Code 204
A frame selector can't set a returnAll
property to true
.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "css",
"returnAll": true
},
"type": "frame"
}
]
}
Error message:
error 204: element "test": frame selector cannot have "returnAll" set to true
Error Code 205
Only a basic element can have nested elements or a shadow root.
Incorrect JSON example:
{
"elements": [
{
"name": "one",
"selector": {
"css": ".one"
},
"elements": [
{
"name": "nestedCustom",
"selector": {
"css": ".nestedCustom"
},
"type": "utam-test/pageObjects/test/componentType",
"public": true
}
],
"shadow": {
"elements": [
{
"name": "nestedInsideShadow",
"selector": {
"css": ".css"
}
}
]
}
}
]
}
Error message:
error 205: element "test": only basic element can have nested elements or shadow root
Error Code 206
The load
property is not supported for elements with arguments or container type elements.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "test[%s]",
"args": [
{
"name": "selectorArgs",
"type": "string"
}
]
},
"load": true
}
]
}
Error message:
error 206: element "test": property "load" is not supported for element with arguments, filter or for container element
Error Code 300
An element filter is incorrectly defined. See Element Filter.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "selector %s",
"returnAll": true,
"args": [
{
"name": "arg1",
"type": "string"
}
]
},
"filter": {
"apply": "wrong",
"args": [
{
"name": "arg1",
"type": "string"
}
]
}
}
]
}
Error message:
error 300: element "test" filter: incorrect format of element filter
Error Code 301
An unknown action is defined for a basic element.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "selector %s",
"returnAll": true,
"args": [
{
"name": "arg1",
"type": "string"
}
]
},
"filter": {
"apply": "wrong",
"args": [
{
"name": "arg1",
"type": "string"
}
],
"matcher": {
"type": "isTrue"
}
}
}
]
}
Error message:
error 301: element "test" filter: unknown action "wrong" for basic element
Error Code 302
A filter can only be set for a list element. See List and Index.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "css"
},
"filter": {
"apply": "isVisible",
"matcher": {
"type": "isTrue"
}
}
}
]
}
Error message:
error 302: element "test" filter: filter can only be set for list
Error Code 303
An unsupported action is defined for this element type. See Basic Element.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"type": "touchable",
"selector": {
"css": "selector %s",
"returnAll": true,
"args": [
{
"name": "arg1",
"type": "string"
}
]
},
"filter": {
"apply": "click",
"matcher": {
"type": "isTrue"
}
}
}
]
}
Error message:
error 303: element "test" filter: unsupported action "click" for type "touchable"
Error Code 400
An interface is incorrectly defined. Declare an interface's API as an array of objects in the methods
property. See Interfaces.
Incorrect JSON example:
{
"interface": true,
"methods": [
{
"name": "test",
"compose": [
{
"element": "root",
"apply": "getText"
}
]
}
]
}
Error message:
error 400: method "test": incorrect format of abstract method
Error Code 401
Reserved for future use.
Error Code 402
A returnAll
property can't be set in an interface without setting a returnType
property. See Interfaces.
Incorrect JSON example:
{
"interface": true,
"methods": [
{
"name": "test",
"returnAll": true
}
]
}
Error message:
error 402: abstract method "test": "returnAll" property can't be set without setting return type
Error Code 403
An unsupported returnType
property for an interface was defined. See Interfaces.
Incorrect JSON example:
{
"interface": true,
"methods": [
{
"name": "test",
"returnType": "container"
}
]
}
Error message:
error 403: abstract method "test": return type "container" is not supported
Error Code 500
The compose method is incorrectly formatted. See Compose Method.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"unsupportedProperty": "value",
"compose": [
{
"element": "root"
}
]
}
]
}
Error message:
error 500: method "test": incorrect format of compose method
Error Code 501
An argument at the method level can't have an argumentReference
type. See Argument Reference.
Incorrect JSON example:
{
"methods": [
{
"args": [
{
"name": "arg1",
"type": "argumentReference"
}
],
"name": "test",
"compose": [
{
"apply": "something"
}
]
}
]
}
Error message:
error 501: method "test" arguments: parameter "arg1" at method level can't have type "argumentReference"
Error Code 502
An argumentReference
is used but there's no matching argument defined at the method level. See Argument Reference.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"apply": "something",
"args": [
{
"name": "arg1",
"type": "argumentReference"
}
]
}
]
}
]
}
Error message:
error 502: method "test": statement declares a reference to an "arg1" argument, but there is no matching argument at the method level
Error Code 503
A declared argument is never used.
Incorrect JSON example:
{
"methods": [
{
"args": [
{
"type": "string",
"name": "arg"
}
],
"name": "test",
"compose": [
{
"apply": "someMethod"
}
]
}
]
}
Error message:
error 503: method "test": declared parameter "arg" is never used
Error Code 504
A duplicate method name is declared. This can be fixed by renaming one of the methods.
Incorrect JSON example:
{
"methods": [
{
"name": "method1",
"compose": [
{
"apply": "someMethod1"
}
]
},
{
"name": "method1",
"compose": [
{
"apply": "someMethod2"
}
]
}
]
}
Error message:
error 504: method "method1": method with the same name was already declared
Error Code 505
The name of a method will duplicate the name of a generated method.
In the example below, the compiler will generate a helper function for the test
element named waitForTest
.
Because there is a declared method with the same name, an error is thrown.
To fix this, rename the element or the method.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": "div"
},
"wait": true,
"public": true
}
],
"methods": [
{
"name": "waitForTest",
"compose": [
{
"element": "test"
}
]
}
]
}
Error message:
error 505: method "waitForTest": the given method name would duplicate the name of a generated helper function for element "test"
Error Code 600
The compose statement is incorrectly formatted. See Compose Method.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"apply": "returnSelf",
"element": "document"
}
]
}
]
}
Error message:
error 600: method "test" statement: incorrect compose statement format
Error Code 601
A compose statement references an unknown element.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "test"
}
]
}
]
}
Error message:
error 601: method "test" statement: unknown element with name "test" is referenced in a compose statement
Error Code 602
A compose statement is using an unsupported returnType
property. See Method Return Types.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "root",
"returnType": "container"
}
]
}
]
}
Error message:
error 602: method "test" statement: return type "container" is not supported in a compose statement
Error Code 603
A compose statement with a returnAll
property must also have a returnType
property. See Compose Method.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "root",
"returnAll": true
}
]
}
]
}
Error message:
error 603: method "test" statement: "returnAll" property can't be set without setting return type in a compose statement
Error Code 605
The return type for element
can't be inferred. Please add a returnType
property.
Incorrect JSON example:
{
"elements": [
{
"name": "element",
"type": "my/pageobject/foo",
"selector": {
"css": "css"
}
}
],
"methods": [
{
"name": "test",
"compose": [
{
"element": "element"
},
{
"chain": true,
"element": "element"
}
]
}
]
}
Error message:
error 605: method "test" statement: can't infer return type for "element", please provide a "returnType"
Error Code 606
An element
property is redundant because it's a chain statement. See Chain Compose Statements.
Incorrect JSON example:
{
"elements": [
{
"name": "element",
"type": "my/custom/type",
"selector": {
"css": "css"
}
}
],
"methods": [
{
"name": "test",
"compose": [
{
"element": "element"
},
{
"chain": true,
"element": "element",
"apply": "method"
}
]
}
]
}
Error message:
error 606: method "test" statement: "element" property is redundant because statement is marked as a chain
Error Code 607
Only a document
or root
element is allowed in a beforeLoad
statement. See beforeLoad.
Incorrect JSON example:
{
"beforeLoad": [
{
"element": "test",
"apply": "getAttribute"
}
]
}
Error message:
error 607: method "beforeLoad" statement: only "document" or "root" elements are allowed
Error Code 608
A "returnSelf" statement can only be invoked from the last statement. See returnSelf statement.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"apply": "returnSelf"
},
{
"apply": "someMethod"
}
]
}
]
}
Error message:
error 608: method "test" statement: "returnSelf" can only be invoked from the last statement
Error Code 609
A compose method must define either an element
, apply
, or applyExternal
property. See Compose Method and Imperative Extensions.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [{}]
}
]
}
Error message:
error 609: method "test" statement: either "element" or "apply" or "applyExternal" should be defined
Error Code 610
A compose method can define either an apply
or applyExternal
property, but not both. See Compose Method and Imperative Extensions.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "root",
"apply": "getText",
"applyExternal": {}
}
]
}
]
}
Error message:
error 610: method "test" statement: either "apply" or "applyExternal" should be defined"
Error Code 611
A compose statement that uses an applyExternal
property can't also use element
or apply
properties.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "root",
"applyExternal": {}
}
]
}
]
}
Error message:
error 611: method "test" utility statement: "element" property is redundant
Error Code 612
This method isn't supported for this basic element type. See Basic Actions.
Incorrect JSON example:
{
"exposeRootElement": true,
"methods": [
{
"name": "test",
"compose": [
{
"apply": "click",
"element": "root"
}
]
}
]
}
Error message:
error 612: method "test" statement: unknown method "click" for basic element
Error Code 613
The compose statement has an unexpected returnType
property. See Method Return Types.
Incorrect JSON example:
{
"elements": [
{
"name": "element",
"selector": {
"css": "css"
},
"type": ["actionable"]
}
],
"methods": [
{
"name": "test",
"compose": [
{
"returnType": "string",
"element": "element"
}
]
}
]
}
Error message:
error 613: method "test" statement: incorrect return type; expected "ElementElement", provided is "String"
Error Code 614
Chains are supported only if the previous statement returns a custom type (another page object). See Chain Compose Statements.
Incorrect JSON example:
{
"elements": [
{
"name": "element",
"selector": {
"css": "css"
}
}
],
"methods": [
{
"name": "test",
"compose": [
{
"element": "element"
},
{
"chain": true,
"element": "element"
}
]
}
]
}
Error message:
error 614: method "test" statement: to use chain, previous statement should return custom type, but it returns "BasicElement"
Error Code 615
A nested waitFor
statement isn't supported. See Explicit Waits.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"apply": "waitFor",
"args": [
{
"type": "function",
"predicate": [
{
"apply": "waitFor",
"args": [
{
"type": "function",
"predicate": [
{
"apply": "invoke"
}
]
}
]
}
]
}
]
}
]
}
]
}
Error message:
error 615: method "test" statement: nested waitFor is not supported
Error Code 616
The first statement in a compose method can't set chain
to true
. See Chain Compose Statements.
Incorrect JSON example:
{
"methods": [
{
"name": "test",
"compose": [
{
"element": "root",
"chain": true
}
]
}
]
}
Error message:
error 616: method "test" statement: first statement can't be marked as chain
Error Code 617
This method isn't supported for this element type. See Basic Actions.
Incorrect JSON example:
{
"type": ["editable"],
"methods": [
{
"name": "test",
"compose": [
{
"apply": "click",
"element": "root"
}
]
}
]
}
Error message:
error 617: method "test" statement: unsupported action "click" for type "Editable"
Error Code 700
The description
property is incorrectly formatted. See Page Object Description.
Incorrect JSON example:
{
"elements",
[
{
"name": "test",
"description": true,
"selector": {
"css": "css"
}
}
]
}
Error message:
error 700: element "test" description: format of the description is incorrect
Error Code 800
The profile
property is incorrectly formatted. See Interfaces.
Incorrect JSON example:
{
"profile": [{}],
"implements": "my/pageobjects/type"
}
Error message:
error 800: profile format is incorrect
Error Code 801
The profile name is a duplicate. See Interfaces.
Incorrect JSON example:
{
"profile": [
{
"name": "value"
},
{
"name": "value"
}
],
"implements": "my/pageobjects/type"
}
Error message:
error 801: "profile": duplicate profile name "name"
Error Code 802
The profile has a duplicate value. See Interfaces.
Incorrect JSON example:
{
"profile": [
{
"name":
["same", "same"]
}
]
"implements", "my/pageobjects/type"
}
Error message:
error 802: profile "name": duplicate profile value "same"
Error Code 803
The profile isn't configured. Make sure that the profile is in the compiler configuration file. See Interfaces.
Incorrect JSON example:
{
"profile": [
{
"name": "error"
}
],
"implements": "my/pageobjects/type"
}
Error message:
error 803: profile { "name": "error" } is not configured, make sure it's in compiler config
Error Code 804
A profile with this name isn't configured. Make sure that the profile is in the compiler configuration file. See Interfaces.
Incorrect JSON example:
{
"profile": [
{
"name1": "value1"
}
],
"implements": "my/pageobjects/type"
}
Error message:
error 804: profile with name "name1" is not configured, make sure it's in compiler config
Error Code 805
A profile can only be set for a page object that also sets the implements
property. See Interfaces.
Incorrect JSON example:
{
"profile": [
{
"profile": "test"
}
]
}
Error message:
error 805: "profile" can only be set for a page object that implements an interface
Error Code 806
A profile value can either be a string or a non-empty string array. See Interfaces.
Incorrect JSON example:
{
"profile": [
{
"name": {}
}
],
"implements": "my/pageobjects/type"
}
Error message:
error 806: profile "name": values can either be string or non-empty string array
Error Code 900
The page object is incorrectly formatted.
Incorrect JSON example:
{
"error": true
}
Error message:
error 900: incorrect format of the page object. Unrecognized field "error".
Error Code 901
A non-root page object can't have a selector
property. Either remove the selector
property or add "root": true
. See Root Element.
Incorrect JSON example:
{
"selector": {
"css": "rootSelector"
}
}
Error message:
error 901: non-root page object can't have selector
Error Code 902
A root page object requires a selector
property. Either add a selector
property or remove "root": true
. See Root Element.
Incorrect JSON example:
{
"root": true
}
Error message:
error 902: root page object requires "selector" property
Error Code 903
The platform
property value must be either web
or native
. See Interfaces.
Incorrect JSON example:
{
"platform": "wibblywobblywonder"
}
Error message:
error 903: "platform" property: platform should be a string with "web" or "native" value, instead found "wibblywobblywonder"
Error Code 904
The beforeLoad
property can't have arguments. See beforeLoad.
Incorrect JSON example:
{
"beforeLoad": [
{
"element": "root",
"apply": "getAttribute",
"args": [
{
"type": "string",
"name": "str"
}
]
}
]
}
Error message:
error 904: method "beforeLoad" cannot have parameters
Error Code 905
The the root description
property is incorrectly formatted. See Page Object Description.
Incorrect JSON example:
{
"description": true
}
Error message:
error 905: format of the root description is incorrect
Error Code 1000
The selector
property is incorrectly formatted. See Element Selector.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": "selector"
}
]
}
Error message:
error 1000: element "test": format of selector is incorrect
Error Code 1002
The selector
must contain css
, accessid
, uiautomator
, or classchain
properties. See Element Selector.
Incorrect JSON example:
{
"root": true,
"selector": {}
}
Error message:
error 1002: element "root" selector: one of "css", "accessid", "uiautomator" or "classchain" should be set"
Error Code 1003
The root selector
can only be one of "css", "accessid", "uiautomator", or "classchain". See Element Selector.
Incorrect JSON example:
{
"root": true,
"selector": {
"css": "css",
"accessid": "accessid"
}
}
Error message:
error 1003: element "root" selector: only one of "css", "accessid", "uiautomator" or "classchain" can be set
Error Code 1004
The selector
is using an invalid UiSelector
method. See Element Selector.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"uiautomator": "new UiScrollable(new UiSelector().scrollable(true)).scrollIntoView(new UiSelector().unsupported())"
}
}
]
}
Error message:
error 1004: element "test" selector: unsupported UiSelector method "unsupported", supported methods are checkable, checked, classname, description, descriptioncontains, descriptionstartswith, enabled, selected, resourceid, resourceidmatches
Error Code 1005
The classchain
property in the selector is using unsupported quotes. See Element Selector.
Incorrect JSON example:
{
"selector": {
"classchain": "**/XCUIElementTypeStaticText[\"label == 'something'\"]"
},
"root": true
}
Error message:
error 1005: element "root" selector "label == 'something'": for class chain only one of supported quotes can be set, supported are $,`
Error Code 1006
The classchain
property in the selector can set only one of the supported operators. See Element Selector.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"classchain": "**/XCUIElementTypeStaticText[`label=='something'`]"
}
}
]
}
Error message:
error 1006: element "test" selector "`label=='something'`": for class chain only one of supported operators can be set, supported are ==,BEGINSWITH,ENDSWITH,CONTAINS,OR,AND
Error Code 1100
The elements
property inside shadow
is incorrectly formatted. See Root Element.
Incorrect JSON example:
{
"shadow": {
"elements": [{}]
}
}
Error message:
error 1100: root shadow: incorrect format of elements inside shadow
Error Code 1200
The matcher
property is incorrectly formatted. See Matchers.
Incorrect JSON example:
{
"name": "test",
"selector": {
"css": ".css",
"returnAll": true
},
"filter": {
"apply": "getText",
"matcher": {
"typemisprinted": "stringEquals"
}
}
}
Error message:
error 1200: element "test" filter: incorrect format of matcher
Error Code 1201
The filter matcher type isn't supported. See Matchers.
Incorrect JSON example:
{
"elements": [
{
"name": "test",
"selector": {
"css": ".helloworld",
"returnAll": true
},
"type": "vanilla-js/pageObjects/counter",
"filter": {
"apply": "getText",
"matcher": {
"type": "invalid"
}
}
}
]
}
Error message:
error 1201: element "test" filter matcher: unsupported matcher type "invalid", supported are isTrue, isFalse, notNull, stringContains, stringEquals
Error Code 1202
The apply
method returns a type that's incompatible with the matcher
. See Matchers.
Incorrect JSON example:
{
"methods": [
{
"name": "matcherThrows",
"compose": [
{
"element": "root",
"apply": "getText",
"matcher": {
"type": "isTrue"
}
}
]
}
]
}
Error message:
error 1202: method "matcherThrows" statement matcher: applied method returns type "String", which is only compatible with the following matchers - stringContains, stringEquals, notNull