def _make_canonical_uri(parsed):
    """
    Return the canonical URI for a parsed URL.

    @param parsed: The parsed URL from which to extract the canonical
        URI
    @type parsed: L{urlparse.ParseResult}

    @return: The canonical URI.
    @rtype: L{str}
    """
    path = urllib.quote(parsed.path)
    canonical_parsed = parsed._replace(path=path,
                                       params='', query='', fragment='')
    return urlparse.urlunparse(canonical_parsed)
def _make_canonical_uri ( parsed ) : path = urllib . quote ( parsed . path ) canonical_parsed = parsed . _replace ( path = path , params = '' , query = '' , fragment = '' ) return urlparse . urlunparse ( canonical_parsed )
Return the canonical URI for a parsed URL.

    @param parsed: The parsed URL from which to extract the canonical
        URI
    @type parsed: L{urlparse.ParseResult}

    @return: The canonical URI.
    @rtype: L{str}