Join GitHub today
Change method of reporting target data #4593
In a previous version we were reporting target information by providing a string that is a key and a value which was a dict containing a lot of information. We want to be able to provide a list of keys that will recursively find the right place in a nested dict to store a primitive value (rather than a dictionary) to the reporting method.
I created to helper methods to do this work. One recursively nests they keys with the value, and another does the work of finding the correctly place in an existing dictionary to update with the new nested dict.
These changes will affect how developers call the report_target_info API. As far as I know, no one is using it yet, so we don't need to make any changes to the dev documentation (apart from the method docs itself).
left a comment
Thanks Dorothy. Aside from adding an Exception for trying to overwrite an existing dict with a primitive, this looks good.
Benjy is back tomorrow, so let's wait for his go before merging.