Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions blog/2022-07-29-device-tracker_source-type-deprecation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
author: Marc Mueller
authorURL: https://github.com/cdce8p
title: "Device tracker deprecations for 2022.9"
---

For Home Assistant Core 2022.9, we have deprecated the `device_tracker`
`SOURCE_TYPE_*` constants.
Use the new [`SourceType`](/docs/core/entity/device-tracker) enum instead.

Deprecated constants:

- `SOURCE_TYPE_GPS`
- `SOURCE_TYPE_ROUTER`
- `SOURCE_TYPE_BLUETOOTH`
- `SOURCE_TYPE_BLUETOOTH_LE`
4 changes: 2 additions & 2 deletions docs/core/entity/device-tracker.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ ScannerEntity does not support attribute shorthand for [property implementation]

| Name | Type | Default | Description |
| ------------- | ------- | ------------ | ------------------------------------------------- |
| source_type | string | **Required** | The source type, eg `gps` or `router`, of the device. |
| source_type | SourceType | **Required** | The source type, eg `gps` or `router`, of the device. |
| is_connected | boolean | **Required** | The connection state of the device. |
| battery_level | integer | `None` | The battery level of the device. |
| ip_address | string | `None` | The IP address of the device. |
Expand Down Expand Up @@ -54,7 +54,7 @@ TrackerEntity does not support attribute shorthand for [property implementation]

| Name | Type | Default | Description |
| ----------------- | ------- | ------------ | ------------------------------------------------- |
| source_type | string | **Required** | The source type, eg `gps` or `router`, of the device. |
| source_type | SourceType | **Required** | The source type, eg `gps` or `router`, of the device. |
| latitude | string | **Required** | The latitude coordinate of the device. |
| longitude | string | **Required** | The longitude coordinate of the device. |
| battery_level | integer | `None` | The battery level of the device. |
Expand Down