add max window calculation for children
Merge pull request #5151 from dimagi/child-max-window

add max window calculation for children