It is a bad practice only if you mutate the mutable object ;-) Having the import inside the function is not beautiful either, but it is also true that the DummyMonitor should live in the performance.py module.
I cannot think of a solution that I fully like, so I will go with that for the moment.