PSLmodels / ParamTools

Library for parameter processing and validation with a focus on computational modeling projects
https://paramtools.dev
MIT License
19 stars 14 forks source link

Fix case where overriding class attr to use default #104

Closed hdoupe closed 4 years ago

hdoupe commented 4 years ago

Fixes bug where the user isn't able to revert an ops argument back to the default value:

class Params3(Parameters):
    array_first = True
    defaults = {"schema": {"operators": {"array_first": True}}}

params = Params3(array_first=False)
# Bug: params.array_first == True
# Fix: params.array_first == False