Issue30

Title 'mb edit' can fail to parse edited content for empty lines
Priority bug Status resolved
Superseder Nosy List poeml
Assigned To poeml Keywords

Created on 2009-12-03.10:21:03 by poeml, last changed by poeml.

Messages
msg247 (view) Author: poeml Date: 2010-09-17.14:07:01
...and r8130.

It turned out that the original issue, reported here, wasn't working anymore. 
r8130 now properly ignores the trailing space after the colon.

http://svn.mirrorbrain.org/viewvc/mirrorbrain?view=revision&revision=8130
msg246 (view) Author: poeml Date: 2010-09-17.13:43:05
I believe that this fix caused a regression. It wasn't possible anymore to remove 
an URL (setting the value to empty). 

Fixed in trunk r8129.

http://svn.mirrorbrain.org/viewvc/mirrorbrain?view=revision&revision=8129

(To become available in 2.13.1.)
msg206 (view) Author: poeml Date: 2010-09-01.16:34:37
I believe this is fixed.

About to appear in 2.13.0.
msg190 (view) Author: poeml Date: 2010-05-04.16:47:01
Fixed in trunk, r8044.
msg189 (view) Author: poeml Date: 2010-05-04.16:02:49
Another failure with copy and paste is this:

When copying output from commit diffs (captured via mb "mb export --commit=svn"), 
statusBaseurl is missing in the output.

When pasting that output into "mb edit", mb edit will fail to save the entry for 
this reason.

How to reproduce: run "mb edit", remove statusBaseurl line, and try to save.
msg83 (view) Author: poeml Date: 2009-12-03.10:21:03
When editing a mirror record with 'mb edit', and removing the trailing space 
after the colon of an empty variable, a parse failure will result when trying to 
save the data.

This can happen if a complete mirror record is copy&pasted from somewhere else, 
and trailing spaces get lost during this mouse action.

Traceback is:

Save changes?
y)es, n)o, e)dit again: y
Traceback (most recent call last):
  File "/usr/bin/mb", line 1187, in <module>
    sys.exit( mirrordoctor.main() )
  File "/var/lib/python-support/python2.5/cmdln.py", line 257, in main
    return self.cmd(args)
  File "/var/lib/python-support/python2.5/cmdln.py", line 280, in cmd
    retval = self.onecmd(argv)
  File "/var/lib/python-support/python2.5/cmdln.py", line 412, in onecmd
    return self._dispatch_cmd(handler, argv)
  File "/var/lib/python-support/python2.5/cmdln.py", line 1100, in _dispatch_cmd
    return handler(argv[0], opts, *args)
  File "/usr/bin/mb", line 516, in do_edit
    if str(old_dict[i]) != new_dict[i]:
KeyError: 'publicNotes'
History
Date User Action Args
2010-09-17 14:07:06poemlsetstatus: chatting -> resolved
2010-09-17 14:07:01poemlsetstatus: resolved -> chatting
messages: + msg247
2010-09-17 13:43:12poemlsetstatus: chatting -> resolved
2010-09-17 13:43:05poemlsetstatus: resolved -> chatting
messages: + msg246
2010-09-01 16:34:37poemlsetstatus: testing -> resolved
messages: + msg206
2010-05-04 16:47:02poemlsetstatus: in-progress -> testing
messages: + msg190
2010-05-04 16:02:49poemlsetmessages: + msg189
2009-12-07 03:15:02poemlsetstatus: unread -> in-progress
2009-12-03 10:21:03poemlcreate