HYDRA-2099 : Handle invalid primitives from MRenderItems#378
HYDRA-2099 : Handle invalid primitives from MRenderItems#378debloip-adsk merged 3 commits intodevfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR replaces assertions with runtime error messages when encountering unsupported primitive types from MRenderItems. Instead of crashing in debug builds, the code now logs descriptive error messages and continues execution.
Changes:
- Replaced
assert(false)withTF_RUNTIME_ERRORmacro calls in two locations - Added detailed error messages including primitive type, item name, DAG path, and prim ID
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 1 comment.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| TF_RUNTIME_ERROR( | ||
| "Unsupported render item primitive %d for item '%s' (prim '%s', id '%s').", | ||
| static_cast<int>(GetPrimitive()), | ||
| _name.asChar(), | ||
| _dagPath.fullPathName().asChar(), | ||
| GetID().GetText()); |
There was a problem hiding this comment.
The error message construction is duplicated in two locations. Consider extracting this error reporting logic into a private helper method to improve maintainability and ensure consistency.
There was a problem hiding this comment.
What is the root cause of these unsupported primitive types? Do we have a ticket to investigate this?
There was a problem hiding this comment.
@lanierd-adsk This conversation was marked resolved previously, do we have an answer to this?
There was a problem hiding this comment.
Logged as HYDRA-2100.
| TF_RUNTIME_ERROR( | ||
| "Unsupported render item primitive %d for item '%s' (prim '%s', id '%s').", | ||
| static_cast<int>(GetPrimitive()), | ||
| _name.asChar(), | ||
| _dagPath.fullPathName().asChar(), | ||
| GetID().GetText()); |
There was a problem hiding this comment.
What is the root cause of these unsupported primitive types? Do we have a ticket to investigate this?
No description provided.