PFython / cleverdict

A JSON-friendly data structure which allows both object attributes and dictionary keys and values to be used simultaneously and interchangeably.
MIT License
101 stars 9 forks source link

Ability to auto-delete #11

Closed PFython closed 3 years ago

PFython commented 3 years ago

Just as the dummy .save() method is called every time a CleverDict values changes, how about a dummy .delete() method for when a value is deleted?

This came to light when using CleverDict to auto-save to a JSON config file... updates were happening beautifully behind the scenes but when an value was deleted, it remained in the config file, meaning that the next time the script was run and the default values were loaded from the config file, the old unwanted value was still there.

PFython commented 3 years ago

Fixed in Version 1.7.4rc2:

pip install -i https://test.pypi.org/simple/ cleverdict==1.7.4rc2