sum (if( week<= max( total aggr(if(year=2020,week),week,year)) and year=2020 , Pratiche))
the trick was "total". The "total" makes it useless the aggr() so the above become the same of:
sum (if( week<= max( total if(year=2020,week)) and year=2020 , Pratiche))
which is a wiser method to obtain what I needed
I don't really get it anyway, I mean, it wasn't a true nested aggregation from the beginning as it is working on the condition, and not the data and anyway I was using aggr().