Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PrimCompositionQuery garbage collection fix #1297

Conversation

fabal
Copy link
Contributor

@fabal fabal commented Aug 19, 2020

Description of Change(s)

When a PrimCompositionQuery python is created then garbage collected, the underlying c++ objects are not properly destructed. Among other things, this prevents unused layers to be discarded.

from pxr import Sdf, Usd

def func():
    s = Usd.Stage.CreateInMemory()
    Usd.PrimCompositionQuery(s.GetPseudoRoot())

func()

assert not Sdf.Layer.GetLoadedLayers()

Fixes Issue(s)

  • Layers are not destroyed upon the garbage collection of a python PrimCompositionQuery object

@jtran56
Copy link

jtran56 commented Aug 24, 2020

Filed as internal issue #USD-6301

@pixar-oss pixar-oss merged commit b8f8d8e into PixarAnimationStudios:dev Sep 14, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants