1 min readMay 13, 2020
Nice article!
One remark concerning your second snippet though…
In the signature of data_classification you are using an empty list as default for the data value.
This is quite dangerous and can lead to unexpected behaviour (but by chance it doesn’t in your case), due to the fact that in Python a definition of a function (and it’s signature) is evaluated when first encountered. p
It would be better, also for dicts etc, to default to None instead.