The order of indices returned by df(e) is 1,2,3,4,5,6,0 instead of 1,2,3,4,5,6,7.
Minimal example of issue:
1. Set first day of the week in settings to whatever day tomorrow is (i.e. if today is Tuesday, set Wednesday as first day).
2. Create text item with $df(e)$ as formula.
3. Expected output: 7, actual output: 0
It seems to have been an issue before but was definitely fixed in between:
https://help.kustom.rocks/i1501-bug-function-df-e-day-of-the-week-is-shifted-of-one-day