def _gerrit_user_to_author(props, username=u'unknown'):
 username = props.get('username', username)
 username = props.get('name', username)
 if ('email' in props):
  username += (u' <%(email)s>' % props)
 return username

def _gerrit_user_to_author ( props , username = u'unknown' ) : username = props . get ( 'username' , username ) username = props . get ( 'name' , username ) if ( 'email' in props ) : username += ( u' <%(email)s>' % props ) return username
convert gerrit account properties to buildbot format take into account missing values .