(doc)
return text_type(symbol)
Decode a JSON symbol to Python string.
Decode a JSON symbol to Python string.
Decode a JSON symbol to Python string .
def _parse_canonical_symbol(doc):
    """Decode a JSON symbol to Python string."""
    symbol = doc['$symbol']
    if len(doc) != 1:
        raise TypeError('Bad $symbol, extra field(s): %s' % (doc,))
    return text_type(symbol)
def _parse_canonical_symbol ( doc ) : symbol = doc [ '$symbol' ] if len ( doc ) != 1 : raise TypeError ( 'Bad $symbol, extra field(s): %s' % ( doc , ) ) return text_type ( symbol )