Frappe chart in child doc

I am trying to show frappe chart on child doc .
but it shows for less than second and hides immediately.

when I test the same code on a normal doc it works fine.
any idea