Forum Discussion

tim_beynart's avatar
tim_beynart
Channel Surfer
9 years ago

RAF logs errors when no ads available

Similar to https://forums.roku.com/viewtopic.php?f=34&t=92104, when I have RAF enabled and I switch to linear content (which has no ads), I start seeing these messages in the log during playback:
BRIGHTSCRIPT: ERROR: Runtime: FOR EACH value is Invalid: roku_ads_lib:/Roku_Ads.brs(3316)

This also happens when I switch to VOD content with no ads. I am using SSAI and am using stitchedAdsInit to load the ad data. This happens in Roku_Ads Framework version 2.0.
Is suspect this is just poor validation of ad data in RAF, but is there something I should be concerned about? My QA team is reluctant to sign off on an app that logs a ton of errors around ad logic.

2 Replies

  • "tim_beynart" wrote:
    Similar to https://forums.roku.com/viewtopic.php?f=34&t=92104, when I have RAF enabled and I switch to linear content (which has no ads), I start seeing these messages in the log during playback:
    BRIGHTSCRIPT: ERROR: Runtime: FOR EACH value is Invalid: roku_ads_lib:/Roku_Ads.brs(3316)

    This also happens when I switch to VOD content with no ads. I am using SSAI and am using stitchedAdsInit to load the ad data. This happens in Roku_Ads Framework version 2.0.
    Is suspect this is just poor validation of ad data in RAF, but is there something I should be concerned about? My QA team is reluctant to sign off on an app that logs a ton of errors around ad logic.

    This particular diagnostic - i checked the line in source - nothing for you to be worried about. It is a warning from FOR EACH loop being asked to enumerate over `invalid` - which value was chosen to indicate empty list in another place. I am taking a note for us to fix this in next version, however. Thank you and keep reporting such concerns.
  • Awesome, thanks for the reassurance. 
    I ended up disabling the call to stitchedAdHandledEvent in the event loop when we play back content with no ads, which I am guessing effectively disables RAF for this use case.