Thanks a lot for this Lorna Jane.

I think your Python code lost indentation after posting it in this page.
Do you have that notes.py file shared on github gist or alike?