Closed
Fix ListPrims returning invalid path information#264
Conversation
Co-authored-by: syoyo <18676+syoyo@users.noreply.github.com>
Updated TraverseRec and TraverseShaderRec functions to: - Use prim.absolute_path() when it's valid and non-empty - Fall back to constructing path from element_name() otherwise This fixes the issue where ListPrims would return prims with <#INVALID#> path information when absolute paths weren't set. Co-authored-by: syoyo <18676+syoyo@users.noreply.github.com>
- Added proper unit test in tests/unit/unit-listprims.cc - Removed test binaries from git tracking - Added test binaries to .gitignore - All unit tests passing including new listprims_test Co-authored-by: syoyo <18676+syoyo@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix ListPrims not populating path information
Fix ListPrims returning invalid path information
Nov 20, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ListPrimswas returning Prims with<#INVALID#>paths becauseTraverseRecusedprim.local_path()(reserved for composition, often unset) instead of the computed absolute path.Changes
src/tydra/scene-access.cc: UpdatedTraverseRecandTraverseShaderRecto:prim.absolute_path()when available (set byStage::compute_absolute_prim_path_and_assign_prim_id())prim.element_name()otherwisetests/unit/unit-listprims.{h,cc}: Added unit test covering both scenarios (with/without computed absolute paths)Example
The fix maintains backward compatibility for both file-loaded Stages (where absolute paths are computed automatically) and programmatically created Stages (where they may not be).
Original prompt
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.