Skip to content
This repository has been archived by the owner on Sep 20, 2024. It is now read-only.

Settings: Conditional dictionary avoid invalid logs #2956

Merged
merged 3 commits into from
Mar 28, 2022

Conversation

iLLiCiTiT
Copy link
Member

Brief description

Conditional dictionary which has children with same key but different types does not cause warning logs when loading settings anymore.

Description

Added option to not log invalid value type on loading of settings which is by default enabled but (currently only) dict-conditional may disable it if is updating values of children which may have different type which is not importatnt.

Changes

  • added argument to update_default_values, update_studio_values and update_project_values which will define if invalid value type is logged out
  • when this argument is passed and value has invalid type it is not logged out
  • conditional dictionary changes the enabled logging based on enum value from the values

Testing notes:

  1. Run settings UI
  2. Check logs in console if there are any warnings

@iLLiCiTiT iLLiCiTiT self-assigned this Mar 28, 2022
@iLLiCiTiT iLLiCiTiT added the type: bug Something isn't working label Mar 28, 2022
Copy link
Member

@kalisp kalisp left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed project_settings/nuke/publish/ExtractReviewDataMov/outputs/baking/reformat_node_config/0/value Got invalid value type for default values. Expected types: (<class 'bool'>,) | Got Type: <class 'str'> | Value: "to format" . warnings.
Save and restart works.

@iLLiCiTiT iLLiCiTiT merged commit 50550c5 into develop Mar 28, 2022
@iLLiCiTiT iLLiCiTiT deleted the bugfix/conditional_dict_invalid_logs branch March 28, 2022 09:44
@mkolar mkolar added this to the next milestone Apr 4, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants