Files
aiomql/docs/core/errors.md
T

30 lines
980 B
Markdown
Raw Normal View History

2024-02-12 21:09:28 +01:00
# Errors
2023-10-11 09:49:06 +01:00
2024-02-12 21:09:28 +01:00
## Tabel of contents
- [Error](#errors.Error)
- [is_connection_error](#errors.is_connection_error)
2023-10-11 09:49:06 +01:00
2024-02-12 21:09:28 +01:00
<a id="errors.Error"></a>
## Error
2023-10-11 09:49:06 +01:00
```python
class Error()
```
Error class for handling errors from MetaTrader 5.
2024-02-12 21:09:28 +01:00
#### Attributes
| Name | Type | Description |
|----------------|--------|----------------------------------------------|
| `code` | `int` | Error code |
| `description` | `str` | Error description |
| `descriptions` | `dict` | A dictionary of error codes and descriptions |
2023-10-11 09:49:06 +01:00
2024-02-12 21:09:28 +01:00
<a id="errors.is_connection_error"></a>
## is_connection_error
```python
def is_connection_error(self) -> bool
```
Check if error is a connection error.
#### Returns
| Type | Description |
|--------|------------------------------------------------------|
| `bool` | True if error is a connection error, False otherwise |