# Errors Skema uses [err-object](https://github.com/kaelzhang/node-err-object) to standardize error objects. There are two kinds of errors - data errors - initialization errors ## Initialization Errors Initialization errors are generated by methods other than `.from()`, such as `shape()`, `type()`, etc. And they have following properties: - **code** `string(UPPERCASED_STRING)` error codes. - **message** `string` The error message. - **args** `Array` The arguments passed to message template of the error. ```js Error { message: "unknown type 'hahaha'", args: ['hahaha'], code: 'UNKNOWN_TYPE' } ``` ## Data Errors Data errors are generated by `.from()` method, and have following properties: - **input** `any` The input value of the current property - **key** `string | number | null` the key of the current property - `string` if the parent is an object - `number` if the parent is an array - `null` if there is no parent - **path** The accessing path of keys to reach the current property - **code** - **message** - **args** [Examples🔬](https://jsfiddle.net/kaelzhang/scvLn8Ly/)