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

Call UpdateAssetInfo after layer is saved #3402

Open
roggiezhang-nv opened this issue Nov 6, 2024 · 2 comments
Open

Call UpdateAssetInfo after layer is saved #3402

roggiezhang-nv opened this issue Nov 6, 2024 · 2 comments
Labels
needs review Issue needing input/review by the repo maintainer (Pixar)

Comments

@roggiezhang-nv
Copy link
Contributor

Description of Issue

Is there any reason why UpdateAssetInfo is not called after layer is saved? Forgetting that may cause out of sync issue for layer's version info if any customized resolver has valid version info needs to be updated.

Steps to Reproduce

from pxr import Usd, Sdf

stage = Usd.Stage.Open("xxxx") 
stage.Save()
print(stage.GetRootLayer().version)
stage.DefinePrim("/test")
stage.Save()
print(stage.GetRootLayer().version)
stage.GetRootLayer().UpdateAssetInfo()
print(stage.GetRootLayer().version)

This snippet may not print valid information for stock USD. You can reproduce it with any resolver that has valid version information for a layer (like Omniverse Composer).

System Information (OS, Hardware)

Package Versions

Build Flags

@roggiezhang-nv
Copy link
Contributor Author

@nvmkuruc

@jesschimein
Copy link
Contributor

Filed as internal issue #USD-10404

@nvmkuruc nvmkuruc added the needs review Issue needing input/review by the repo maintainer (Pixar) label Nov 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs review Issue needing input/review by the repo maintainer (Pixar)
Projects
None yet
Development

No branches or pull requests

3 participants