Search Unity

  1. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice
  2. Ever participated in one our Game Jams? Want pointers on your project? Our Evangelists will be available on Friday to give feedback. Come share your games with us!
    Dismiss Notice

Help - A PlayableGraph is being directly or indirectly evaluated recursively.

Discussion in 'Timeline' started by JennyHide, Jun 22, 2020.

  1. JennyHide

    JennyHide

    Joined:
    Sep 30, 2014
    Posts:
    40
    Hello,

    I'm getting the error message "A PlayableGraph is being directly or indirectly evaluated recursively." when I call

    Code (CSharp):
    1. playableDirector.RebuildGraph();
    I'm calling RebuildGraph() when I change the current Timeline playable asset in code. The error message doesn't show for every timeline, but it does always show for two specific timelines (it happens to be the two that I've made recently. The others were made months ago). The new timelines don't use anything different in them - the tracks they use are all used elsewhere.

    The error message doesn't seem to do anything most of the time - I can keep playing the game. BUT sometimes, the game (both the build and the Unity editor) crashes here. I still get the error message. The crash dump indicates the crash happens in Unity.exe!PlayableOutput::GetSourcePlayable(void).

    Since I can't look into Unity's .cpp files, I can't see what's going wrong.. any ideas?

    Thanks,
    Jenny
     
  2. seant_unity

    seant_unity

    Unity Technologies

    Joined:
    Aug 25, 2015
    Posts:
    1,309
    This usually means that the timeline is somehow self referencing. For example, if you are using nested timelines with control tracks, and one of the clips tries to control a playable director at a higher level.
     
  3. JennyHide

    JennyHide

    Joined:
    Sep 30, 2014
    Posts:
    40
    Hello,

    I'm not using any nested timelines.

    I've just tried swapping the Timeline that causes it with a new, empty one. I still get the "A PlayableGraph is being directly or indirectly evaluated recursively." error when I set the new one. And I've just managed to get the crash again with this empty timeline.

    Jenny
     
  4. seant_unity

    seant_unity

    Unity Technologies

    Joined:
    Aug 25, 2015
    Posts:
    1,309
    Are you using any custom built tracks on the old one?
     
  5. JennyHide

    JennyHide

    Joined:
    Sep 30, 2014
    Posts:
    40
    Yes - several. I've managed to 'fix' this by just not using

    Code (CSharp):
    1. RebuildGraph();
    after changing the current Timeline playable asset. It seems to work fine without it!
     
unityunity