Description
If I click on "Edit (GUI)", it will start loading. If I now hit "Cancel", I get an error.
Steps to reproduce
- Click "Edit (GUI)".
- Click "Cancel".
Example
--> --> TypeError coercing to Unicode: need string or buffer, NoneType found If you want to report a bug, please save this page and attach it to your bug report. * Show debugging information * Report bug * Visit MoinMoin wiki Traceback A problem occurred in a Python script. Here is the sequence of function calls leading up to the error, in the order they occurred. 1. /org/moin_tw/moin-1.5/MoinMoin/request.py in run (self=<MoinMoin.request.RequestTwisted object>) 1. 1006 from MoinMoin.wikiaction import getHandler 2. 1007 handler = getHandler(self, action) 3. 1008 handler(self.page.page_name, self) 4. 1009 5. 1010 # 5. Or redirect to another page * handler = <function do_edit> * self = <MoinMoin.request.RequestTwisted object> * self.page = <MoinMoin.Page.Page instance> * self.page.page_name = u'MoinMoinBugs' 2. /org/moin_tw/moin-1.5/MoinMoin/wikiaction.py in do_edit (pagename=u'MoinMoinBugs', request=<MoinMoin.request.RequestTwisted object>) 1. 566 # Edit was canceled 2. 567 if request.form.has_key('button_cancel'): 3. 568 pg.sendCancel(savetext, rev) 4. 569 return 5. 570 * pg = <MoinMoin.PageGraphicalEditor.PageGraphicalEditor instance> * pg.sendCancel = <bound method PageGraphicalEditor.sendCancel of ...ageGraphicalEditor.PageGraphicalEditor instance>> * savetext = None * rev = 555 3. /org/moin_tw/moin-1.5/MoinMoin/PageEditor.py in sendCancel (self=<MoinMoin.PageGraphicalEditor.PageGraphicalEditor instance>, newtext=None, rev=555) 1. 432 """ 2. 433 _ = self._ 3. 434 self._make_backup(newtext) 4. 435 self.lock.release() 5. 436 * self = <MoinMoin.PageGraphicalEditor.PageGraphicalEditor instance> * self._make_backup = <bound method PageGraphicalEditor._make_backup o...ageGraphicalEditor.PageGraphicalEditor instance>> * newtext = None 4. /org/moin_tw/moin-1.5/MoinMoin/PageEditor.py in _make_backup (self=<MoinMoin.PageGraphicalEditor.PageGraphicalEditor instance>, newtext=None, **kw={}) 1. 668 intro += _('## backup of page "%(pagename)s" submitted %(date)s') % { 2. 669 'pagename': pagename, 'date': date,} + u'\n' 3. 670 backuppage._write_file(intro + newtext) 4. 671 5. 672 return backuppage.url(self.request) * backuppage = <MoinMoin.PageEditor.PageEditor instance> * backuppage._write_file = <bound method PageEditor._write_file of <MoinMoin.PageEditor.PageEditor instance>> * intro = u'#acl Allefant:read,write,delete All:\n\n' * newtext = None TypeError coercing to Unicode: need string or buffer, NoneType found * args = ('coercing to Unicode: need string or buffer, NoneType found',) System Details * Date: Sun, 13 Nov 2005 15:43:42 +0000 * Platform: Linux thinkmo 2.6.14-thinkmo-1 #1 SMP Wed Nov 9 17:33:56 CET 2005 x86_64 * Python: Python 2.4.2 (/usr/local/bin/python2.4) * MoinMoin: Release 1.5.0beta3 (release)
Details
This Wiki
Workaround
Always wait until the page is loaded before hitting Cancel. Hard to do on slow servers.
Discussion
Plan
- Priority:
- Assigned to:
Status: duplicate of EditCancelBeforePageIsLoaded, fixed in 1.5 patch 225