I have an automation which triggers when an sms is received. Then i compare the sender number in template condition to a list of numbers (about 500 numbers).
Mostly it works as expected, but sometimes the condition returns false even though the number is in the list. Then with another try it returns true.
This is very strange. What can be wrong? The number and message are written to file with notify before comparing.
{%
set phone_numbers = [
"+3581234567",
"+3580987654"] %}
{{ trigger.event.data.phone in phone_numbers and
trigger.event.data.text.lower().replace(" ", "") == 'open' }}