Yes, it certainly isn't a feature, especially considering the "random" nature.
There is a problem somewhere - but unfortunatelly the code is not that simple (as a simple "whitelisting" of avast.setup - if it were, and it had been forgotten, the window would pop up each time, not just sometimes). Vlk is checking the code, but right now the cause is unknown.
Btw, my
guess is that
this and
this are actually manifestations of the same problem. Let's hope it will be found soon.