def _expand_node(node):
 ret = {}
 ret.update(node.__dict__)
 try:
  del ret['extra']['boot_disk']
 except Exception:
  pass
 zone = ret['extra']['zone']
 ret['extra']['zone'] = {}
 ret['extra']['zone'].update(zone.__dict__)
 return ret

def _expand_node ( node ) : ret = { } ret . update ( node . __dict__ ) try : del ret [ 'extra' ] [ 'boot_disk' ] except Exception : pass zone = ret [ 'extra' ] [ 'zone' ] ret [ 'extra' ] [ 'zone' ] = { } ret [ 'extra' ] [ 'zone' ] . update ( zone . __dict__ ) return ret
convert the libcloud node object into something more serializable .