/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/smart/request.py

  • Committer: Martin
  • Date: 2011-03-02 20:39:58 UTC
  • mto: This revision was merged to the branch mainline in revision 5694.
  • Revision ID: gzlist@googlemail.com-20110302203958-ky3qss741ljo5f0f
Store exception name after initial 'error' slot as suggested in review

Show diffs side-by-side

added added

removed removed

Lines of Context:
446
446
        return ('TokenMismatch', err.given_token, err.lock_token)
447
447
    elif isinstance(err, errors.LockContention):
448
448
        return ('LockContention',)
 
449
    elif isinstance(err, MemoryError):
 
450
        # GZ 2011-02-24: Copy bzrlib.trace -Dmem_dump functionality here?
 
451
        return ('MemoryError',)
449
452
    # Unserialisable error.  Log it, and return a generic error
450
453
    trace.log_exception_quietly()
451
 
    return ('error', str(err))
 
454
    return ('error', trace._qualified_exception_name(err.__class__, True),
 
455
        str(err))
452
456
 
453
457
 
454
458
class HelloRequest(SmartServerRequest):
510
514
    'bzrlib.smart.branch', 'SmartServerRequestRevisionHistory')
511
515
request_handlers.register_lazy( 'Branch.set_config_option',
512
516
    'bzrlib.smart.branch', 'SmartServerBranchRequestSetConfigOption')
 
517
request_handlers.register_lazy( 'Branch.set_config_option_dict',
 
518
    'bzrlib.smart.branch', 'SmartServerBranchRequestSetConfigOptionDict')
513
519
request_handlers.register_lazy( 'Branch.set_last_revision',
514
520
    'bzrlib.smart.branch', 'SmartServerBranchRequestSetLastRevision')
515
521
request_handlers.register_lazy(