For the following simple wxPython snippets:
import sys
import wx
class MyApp(wx.App):
def OnInit(self):
self.frame = wx.Frame(None, title="Simple wxPython App")
self.frame.Show()
self.SetTopWindow(self.frame)
return True
def main(argv=sys.argv[:]):
app = MyApp()
app.MainLoop()
return 0
if __name__ == '__main__':
sys.exit(main())
I always got the warning message "R0904: 12:MyApp: Too many public methods" from Pylint. How can I prevent that?
# pylint: disable=R0904
Stick that at the top of the offending class.
On older versions of Pylint, you have to use
# pylint: disable-msg=R0904
Unfortunately, if you ever upgrade to a more recent version you'll have to write a sed script to replace all instances of # pylint: disable-msg
with # pylint: disable
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With