script error: no such item (4)

why error in log: script error: no such item (4)
https://pasteboard.co/K4Vqitv.jpg

my script:

:foreach i in=[/ip dns cache find name~"youtube"] do={ :do { /ip firewall address-list add list=YouTube address=[/ip dns cache get $i address]; } on-error={} }
:foreach i in=[/ip dns cache find name~"youtube"] do={ :do { /ip firewall address-list add list=YouTube address=[/ip dns cache get $i name]; } on-error={} }

why try to obtain on second foreach?
the address is already on list and if you try to add both. the second when resolved give an error because resolved IP already exist and the script stop


/ip firewall address-list
:foreach i in=[/ip dns cache find where name~"youtube"] do={
 :local xaddress [/ip dns cache get $i address]
 :if ([:len [find where address=$xaddress]] < 1) do={
  add list=YouTube address=$xaddress comment=[/ip dns cache get $i name]
 }
}

If you want a full address list used by youtube, instead everytime use scripts:
https://bgp.he.net/AS36040#_prefixes