-
Notifications
You must be signed in to change notification settings - Fork 16
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
Attributes: enums with additional metadata #314
Conversation
@Innders Are we adding that priority built-in attribute? |
Co-authored-by: Luke Inderwick <[email protected]>
@Innders i've changed the way defaults propagate to the children entities, so it should now display correctly the default priority set in anatomy or set as default on the attribute. In order to rebuild the hierarchy on the project created before this attribute was introduced, it is necessary to run the setup process (make setup). that will be triggered during server update, so it shouldn't cause issues. |
This pull request introduces several changes to enhance attribute handling, improve error logging, and update project setup processes. The most important changes include adding a new property to fetch project defaults, updating logging methods, and modifying attribute handling in various modules.
Attribute Handling Enhancements:
project_defaults
property inayon_server/entities/core/attrib.py
to fetch default attribute values for projects.parse_attrib_data
andrebuild_inherited_attributes
to utilize the newproject_defaults
property. (ayon_server/graphql/utils.py
: [1]ayon_server/helpers/inherited_attributes.py
: [2]icon
andcolor
fields to theAttributeEnumItem
class inayon_server/types.py
to support additional attribute metadata.Logging Improvements:
logging.error
withlog_traceback
for better error traceability ingenerate_model
function inayon_server/entities/models/generator.py
. [1] [2]Project Setup Updates:
rebuild_inherited_attributes
for each project in the setup process to ensure attributes are correctly initialized insetup/__main__.py
.priority
with enum values and associated metadata insetup/attributes.py
.These changes collectively aim to improve the robustness and maintainability of the attribute handling system and enhance the setup process for new projects.Adds
icon
andcolor
to AttributeEnumItem model.