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

usdview - Don't error or warn in Rollover Prim Info if assetInfo has no identifier entry #1476

Conversation

ablev-dwa
Copy link
Contributor

Description of Change(s)

Changes usdview's Rollover Prim Info mode to gracefully handle cases where the "identifier" assetInfo is not authored on a prim. The existing code expects the data to exist, and will flood the terminal with KeyErrors if it's not actually authored, which also causes the rollover to be incomplete.

This change will make it Rollover Prim Info faster and more useful in pipelines that do not author the identifier assetInfo metadata.

@spiffmon
Copy link
Member

Hi @ablev-dwa ! Would you consider updating that function's comment about what the (now acceptable) fallback behavior is when there is no identifier-bearing layer to find?

@ablev-dwa
Copy link
Contributor Author

Absolutely, sorry, I should have thought of that. I will update the PR tonight.

Signed-off-by: Alan Blevins <alan.blevins@dreamworks.com>
@ablev-dwa ablev-dwa force-pushed the usdview_no_assetInfo_identifier branch from 6406fb3 to 8438caf Compare March 18, 2021 05:53
@ablev-dwa
Copy link
Contributor Author

Updated the docstring for GetAssetCreationTime()

@spiffmon
Copy link
Member

Thanks, @ablev-dwa - looks great! Of course, this function is not Ar 2.0 and non-file-backed-asset friendly at all. But Ar won't give you concrete time/date information, which is why I wrote the function this way in the first place...

@ablev-dwa
Copy link
Contributor Author

That makes sense. We haven't started our journey to Ar2 yet but it will probably be good to start thinking about it :)

@jtran56
Copy link

jtran56 commented Mar 22, 2021

Filed as internal issue #USD-6613

pixar-oss added a commit that referenced this pull request Apr 14, 2021
usdview - Don't error or warn in Rollover Prim Info if assetInfo has no identifier entry

(Internal change: 2159197)
@tallytalwar
Copy link
Contributor

This was merged with commit: e7e6067

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.

6 participants