class MyForm(wx.Frame):

    def __init__(self):
        wx.Frame.__init__(self, None, wx.ID_ANY, 'Tutorial')
self.panel = wx.Panel(self, wx.ID_ANY)
btn = wx.Button(self.panel, label='Change Cursor')
btn.Bind(wx.EVT_BUTTON, self.changeCursor)
sizer = wx.BoxSizer(wx.HORIZONTAL)
sizer.Add(btn)
self.panel.SetSizer(sizer)

def changeCursor(self, event):
    pass
wxPython change mouse cursor to notify a long running operation