Instead of hard-coding it, as it is now:
self.write = self.action in ( "edit", "move", "rollback", "delete", "undelete", "protect", "block", "unblock", "watch", "patrol", "import", "userrights", "upload", "emailuser", "createaccount", "setnotificationtimestamp", "filerevert", "options", "purge", "revisiondelete", "wbeditentity", "wbsetlabel", "wbsetdescription", "wbsetaliases", "wblinktitles", "wbsetsitelink", "wbcreateclaim", "wbremoveclaims", "wbsetclaimvalue", "wbsetreference", "wbremovereferences" )