Skip to content

Bug: Saved qconfig recipe info is being destroyed on load #150

@BrandonGroth

Description

@BrandonGroth

Describe the bug

Loading a qconfig recipe with non-default values is being overwritten in qconfig_load()

Platform

N/A

Sample Code

This function is responsible for the behavior:

def add_wanted_defaults_to_config(config: dict, minimal: bool = True) -> None:
    """Util function to add basic config defaults that are missing into a config
    if a wanted item is not in the config, add it w/ default value
    """
    if not minimal:
        config.update(config_defaults())

Expected behavior

add_wanted_defaults_to_config() should only add a default IF it isn't present already in the recipe

Observed behavior

Any wanted value that was specialized in the qconfig was destroyed due to .update()

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions