Skip to content

Commit 67475ff

Browse files
committed
Add note about Ontario (ON)
1 parent fa00f21 commit 67475ff

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

source/_components/binary_sensor.workday.markdown

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,18 +22,21 @@ To enable the `workday` sensor in your installation, add the following to your `
2222
binary_sensor:
2323
- platform: workday
2424
country: DE
25-
province: BW
2625
```
2726
2827
Configuration variables:
2928
3029
- **country** (*Required*): Country code according to [holidays](https://pypi.python.org/pypi/holidays/0.8.1) notation.
31-
- **province** (*Optional*): Province code according to [holidays](https://pypi.python.org/pypi/holidays/0.8.1) notation (defaults to None).
32-
- **workdays** (*Optional*): List of workdays (defaults to mon, tue, wed, thu, fri).
33-
- **excludes** (*Optional*): List of workday excludes (defaults to sat, sun, holiday).
30+
- **province** (*Optional*): Province code according to [holidays](https://pypi.python.org/pypi/holidays/0.8.1) notation. Defaults to None.
31+
- **workdays** (*Optional*): List of workdays. Defaults to `mon`, `tue`, `wed`, `thu`, `fri`.
32+
- **excludes** (*Optional*): List of workday excludes. Defaults to `sat`, `sun`, `holiday`.
3433

3534
Days are specified as follows: `mon`, `tue`, `wed`, `thu`, `fri`, `sat`, `sun`. The keyword `holiday` is used for public holidays identified by the holidays module.
3635

36+
<p class='note warning'>
37+
If you use the sensor for Canada (`CA`) with Ontario (`ON`) as `province:` then you need to wrap `ON` in quotes. Otherwise the value is evaluated as `True` (check the YAML documentation for further details) and the sensor will not work.
38+
</p>
39+
3740
Example usage for automation:
3841

3942
```yaml

0 commit comments

Comments
 (0)