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

Fix exceptions raised when accessing attributes that either do not exist or are not associated to a graph #1889

Merged
merged 2 commits into from
Feb 8, 2023

Conversation

cbentejac
Copy link
Contributor

Description

This PR fixes two exceptions related to attributes that were raised in some cases:

  • In the Viewer2D, when determining whether the active node relates to the lens distortion viewer, check if the "input" attribute exists for that node before trying to access it. (fixes a KeyError exception)
  • When the attribute's full name and full label within the graph are evaluated, check that the node it belongs to is associated to an existing graph (some nodes may be created temporarily in some specific cases without ever being attached to a graph): if it is, then the attribute's full name/label can be returned, otherwise "UNDEFINED" is. (fixes a ValueError exception)

@cbentejac cbentejac self-assigned this Feb 3, 2023
@fabiencastan fabiencastan added this to the Meshroom 2023.1.0 milestone Feb 8, 2023
@fabiencastan fabiencastan merged commit e2df8f8 into develop Feb 8, 2023
@fabiencastan fabiencastan deleted the fix/attributeErrors branch February 8, 2023 14:09
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.

2 participants