Skip to content

Commit 0938857

Browse files
committed
fix lint errors
1 parent 6057eed commit 0938857

File tree

1 file changed

+5
-2
lines changed
  • sources/platform/actors/development/actor_definition/dataset_schema

1 file changed

+5
-2
lines changed

sources/platform/actors/development/actor_definition/dataset_schema/validation.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,12 +104,13 @@ If the data you attempt to store in the dataset is _invalid_ (meaning any of the
104104
}
105105
```
106106

107-
The type of the AJV validation error object is [here](https://github.com/ajv-validator/ajv/blob/master/lib/types/index.ts#L86).
107+
For the complete AJV validation error object type definition, refer to the [AJV type definitions on GitHub](https://github.com/ajv-validator/ajv/blob/master/lib/types/index.ts#L86).
108108

109109
If you use the Apify JS client or Apify SDK and call `pushData` function you can access the validation errors in a `try catch` block like this:
110110

111111
<Tabs>
112112
<TabItem value="Javascript" label="Javascript" default>
113+
113114
```javascript
114115
try {
115116
const response = await Actor.pushData(items);
@@ -120,8 +121,10 @@ try {
120121
});
121122
}
122123
```
124+
123125
</TabItem>
124126
<TabItem value="Python" label="Python">
127+
125128
```python
126129
from apify import Actor
127130
from apify_client.errors import ApifyApiError
@@ -132,8 +135,8 @@ async with Actor:
132135
except ApifyApiError as error:
133136
if 'invalidItems' in error.data:
134137
validation_errors = error.data['invalidItems']
135-
136138
```
139+
137140
</TabItem>
138141
</Tabs>
139142

0 commit comments

Comments
 (0)