Module Expr Str Assign NameStore ListLoad Str Str Str Str Str Str Assign NameStore ListLoad Str Str Str Str Str Str Str Str Str Str Str Str Str Str Assign NameStore ListLoad Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Assign NameStore ListLoad Str Str Str Str Str Str Str Str Str Assign NameStore ListLoad Str Str Str Str Str Str Str Str Str Str Str Str Assign NameStore ListLoad Str Str Str Str Str Str Str Str Str Str Str Assign NameStore ListLoad Str Str Str Str Str Str Str Str Str Str Str Str Str Assign NameStore Str Assign NameStore Num Assign NameStore Dict FunctionDef arguments args defaults body Expr Str Global identifier Assign NameStore Dict decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults Str Num body Expr Str Assign NameStore Call NameLoad NameLoad NameLoad NameLoad Assign TupleStore NameStore NameStore NameStore NameStore NameStore NameLoad If BoolOpAnd CompareIn NameLoad NameLoad CompareIn Str NameLoad body Assign TupleStore NameStore NameStore Call NameLoad NameLoad orelse Assign NameStore Str Return TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body If CompareIn Str NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Str Call AttributeLoad NameLoad attr Str If CompareLt NameLoad Num body Return TupleLoad NameLoad Str orelse Assign NameStore Call AttributeLoad NameLoad attr Str Return TupleLoad SubscriptLoad NameLoad Slice NameLoad SubscriptLoad NameLoad Slice BinOpAdd NameLoad Num decorator_list FunctionDef arguments args NameParam NameParam defaults Num body For NameStore Str body Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If CompareGtE NameLoad Num body Break orelse Assign NameStore Call NameLoad NameLoad Return TupleLoad SubscriptLoad NameLoad Slice NameLoad NameLoad SubscriptLoad NameLoad Slice NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults Str Num body Expr Str Assign NameStore TupleLoad NameLoad NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If NameLoad body Return NameLoad If CompareGtE Call NameLoad NameLoad NameLoad body Expr Call NameLoad Assign NameStore NameStore NameStore Str Assign NameStore Call AttributeLoad NameLoad attr Str If CompareGt NameLoad Num body If CompareEq SubscriptLoad NameLoad Slice NameLoad Str body Assign NameStore Call AttributeLoad SubscriptLoad NameLoad Slice NameLoad attr Assign NameStore SubscriptLoad NameLoad Slice BinOpAdd NameLoad Num If CompareEq SubscriptLoad NameLoad Slice Num Str body Assign TupleStore NameStore NameStore Call NameLoad NameLoad Num If BoolOpAnd NameLoad CompareIn Str NameLoad body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr Str Num If CompareIn Str NameLoad body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr Str Num Assign NameStore TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad Assign SubscriptStore NameLoad Index NameLoad NameLoad Return NameLoad For NameStore SubscriptLoad NameLoad Slice NameLoad body If CompareNotIn NameLoad NameLoad body Break orelse Assign TupleStore NameStore NameStore TupleLoad Call AttributeLoad SubscriptLoad NameLoad Slice NameLoad attr SubscriptLoad NameLoad Slice BinOpAdd NameLoad Num If BoolOpAnd CompareIn NameLoad NameLoad CompareEq SubscriptLoad NameLoad Slice Num Str body Assign TupleStore NameStore NameStore Call NameLoad NameLoad Num If BoolOpAnd NameLoad CompareIn NameLoad NameLoad CompareIn Str NameLoad body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr Str Num If BoolOpAnd CompareIn NameLoad NameLoad CompareIn Str NameLoad body Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr Str Num Assign NameStore TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad Assign SubscriptStore NameLoad Index NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args TupleStore NameStore NameStore NameStore NameStore NameStore NameStore defaults body Expr Str If NameLoad body Assign NameStore BinOpMod Str TupleLoad NameLoad NameLoad Return Call NameLoad TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args TupleStore NameStore NameStore NameStore NameStore NameStore defaults body If BoolOpOr NameLoad BoolOpAnd NameLoad CompareIn NameLoad NameLoad CompareNotEq SubscriptLoad NameLoad Slice Num Str body If BoolOpAnd NameLoad CompareNotEq SubscriptLoad NameLoad Slice Num Str body Assign NameStore BinOpAdd Str NameLoad Assign NameStore BinOpAdd BinOpAdd Str BoolOpOr NameLoad Str NameLoad If NameLoad body Assign NameStore BinOpAdd BinOpAdd NameLoad Str NameLoad If NameLoad body Assign NameStore BinOpAdd BinOpAdd NameLoad Str NameLoad If NameLoad body Assign NameStore BinOpAdd BinOpAdd NameLoad Str NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults Num body Expr Str If UnaryOpNot NameLoad body Return NameLoad If UnaryOpNot NameLoad body Return NameLoad Assign TupleStore NameStore NameStore NameStore NameStore NameStore NameStore Call NameLoad NameLoad Str NameLoad Assign TupleStore NameStore NameStore NameStore NameStore NameStore NameStore Call NameLoad NameLoad NameLoad NameLoad If BoolOpOr CompareNotEq NameLoad NameLoad CompareNotIn NameLoad NameLoad body Return NameLoad If CompareIn NameLoad NameLoad body If NameLoad body Return Call NameLoad TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad Assign NameStore NameLoad If CompareEq SubscriptLoad NameLoad Slice Num Str body Return Call NameLoad TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad If UnaryOpNot BoolOpOr NameLoad NameLoad NameLoad body Return Call NameLoad TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad Assign NameStore BinOpAdd SubscriptLoad Call AttributeLoad NameLoad attr Str Slice Num Call AttributeLoad NameLoad attr Str If CompareEq SubscriptLoad NameLoad Index Num Str body Assign SubscriptStore NameLoad Index Num Str While CompareIn Str NameLoad body Expr Call AttributeLoad NameLoad attr Str While Num body Assign NameStore Num Assign NameStore BinOpSub Call NameLoad NameLoad Num While CompareLt NameLoad NameLoad body If BoolOpAnd CompareEq SubscriptLoad NameLoad Index NameLoad Str CompareNotIn SubscriptLoad NameLoad Index BinOpSub NameLoad Num TupleLoad Str Str body Delete SubscriptDel NameLoad Slice BinOpSub NameLoad Num BinOpAdd NameLoad Num Break Assign NameStore BinOpAdd NameLoad Num orelse Break If CompareEq NameLoad ListLoad Str Str body Assign SubscriptStore NameLoad Index Num Str orelse If BoolOpAnd CompareGtE Call NameLoad NameLoad Num CompareEq SubscriptLoad NameLoad Index Num Str body Assign SubscriptStore NameLoad Slice Num ListLoad Str Return Call NameLoad TupleLoad NameLoad NameLoad Call AttributeLoad Str attr NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareIn Str NameLoad body Assign TupleStore NameStore NameStore NameStore NameStore NameStore NameStore Call NameLoad NameLoad Assign NameStore Call NameLoad TupleLoad NameLoad NameLoad NameLoad NameLoad NameLoad Str Return TupleLoad NameLoad NameLoad orelse Return TupleLoad NameLoad Str decorator_list Assign NameStore Str FunctionDef arguments args defaults body Import alias Assign NameStore Str If SubscriptLoad AttributeLoad NameLoad attr Slice Num body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index Num If CompareEq NameLoad Str body Assign NameStore AttributeLoad NameLoad attr orelse Assign NameStore Call NameLoad NameLoad orelse Import alias Assign NameStore Call AttributeLoad NameLoad attr NameLoad While Num body Assign NameStore Call AttributeLoad NameLoad attr If UnaryOpNot NameLoad body Break Assign NameStore Call AttributeLoad NameLoad attr If UnaryOpNot NameLoad body Continue Assign NameStore SubscriptLoad NameLoad Index Num Assign NameStore Call NameLoad NameLoad Print BinOpMod Str TupleLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad NameLoad If UnaryOpNot NameLoad body Assign NameStore NameLoad Assign NameStore BinOpMod Str NameLoad Print BinOpMod Str TupleLoad NameLoad NameLoad If BoolOpAnd CompareEq Call NameLoad NameLoad Num CompareEq SubscriptLoad NameLoad Index Num Str body If CompareNotEq NameLoad SubscriptLoad NameLoad Index Num body Print Str SubscriptLoad NameLoad Index Num Str decorator_list If CompareEq NameLoad Str body Expr Call NameLoad
N/A N/A Parse (absolute and relative) URLs.

See RFC 1808: "Relative Uniform Resource Locators", by R. Fielding,
UC Irvine, June 1995.
 N/A __all__ N/A urlparse urlunparse urljoin urldefrag urlsplit urlunsplit N/A uses_relative N/A ftp http gopher nntp imap wais file https shttp mms prospero rtsp rtspu N/A uses_netloc N/A ftp http gopher nntp telnet imap wais file mms https shttp snews prospero rtsp rtspu rsync svn svn+ssh N/A non_hierarchical N/A gopher hdl mailto news telnet wais imap snews sip N/A uses_params N/A ftp hdl prospero http imap https shttp rtsp rtspu sip mms N/A uses_query N/A http wais imap https shttp mms gopher rtsp rtspu sip N/A uses_fragment N/A ftp hdl http gopher news nntp wais https shttp snews file prospero N/A scheme_chars abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789+-. N/A MAX_CACHE_SIZE 20 N/A _parse_cache N/A clear_cache N/A N/A N/A N/A N/A Clear the parse cache. N/A _parse_cache N/A _parse_cache N/A N/A urlparse N/A N/A url scheme allow_fragments N/A 1 N/A N/A Parse a URL into 6 components:
    <scheme>://<netloc>/<path>;<params>?<query>#<fragment>
    Return a 6-tuple: (scheme, netloc, path, params, query, fragment).
    Note that we don't break the components up in smaller bits
    (e.g. netloc is a single string) and we don't expand % escapes. N/A tuple N/A urlsplit url scheme allow_fragments N/A N/A scheme netloc url query fragment tuple N/A N/A N/A scheme uses_params N/A ; url N/A N/A N/A url params N/A _splitparams url N/A N/A params N/A N/A scheme netloc url params query fragment N/A _splitparams N/A N/A url N/A N/A N/A N/A / url N/A N/A i N/A N/A url find ; N/A N/A url rfind / N/A N/A i 0 N/A N/A N/A url N/A N/A i N/A N/A url find ; N/A N/A N/A url N/A i N/A url N/A N/A i 1 N/A _splitnetloc N/A N/A url start N/A 0 N/A N/A c /?# N/A N/A delim N/A N/A url find c start N/A N/A delim 0 N/A N/A N/A N/A delim N/A len url N/A N/A N/A url N/A start delim N/A url N/A delim N/A urlsplit N/A N/A url scheme allow_fragments N/A 1 N/A N/A Parse a URL into 5 components:
    <scheme>://<netloc>/<path>?<query>#<fragment>
    Return a 5-tuple: (scheme, netloc, path, query, fragment).
    Note that we don't break the components up in smaller bits
    (e.g. netloc is a single string) and we don't expand % escapes. N/A key N/A url scheme allow_fragments N/A cached N/A N/A _parse_cache get key None N/A cached N/A N/A cached N/A N/A N/A len _parse_cache MAX_CACHE_SIZE N/A N/A N/A clear_cache N/A netloc query fragment N/A i N/A N/A url find : N/A N/A i 0 N/A N/A N/A N/A url N/A i http N/A N/A scheme N/A N/A N/A url N/A i lower N/A url N/A url N/A N/A i 1 N/A N/A N/A url N/A 2 // N/A N/A N/A netloc url N/A _splitnetloc url 2 N/A N/A allow_fragments N/A # url N/A N/A N/A url fragment N/A N/A url split # 1 N/A N/A ? url N/A N/A N/A url query N/A N/A url split ? 1 N/A tuple N/A scheme netloc url query fragment N/A N/A _parse_cache N/A key tuple N/A tuple N/A c N/A url N/A i N/A N/A N/A c scheme_chars N/A N/A N/A N/A N/A scheme url N/A N/A N/A N/A url N/A i lower N/A url N/A N/A i 1 N/A N/A N/A scheme uses_netloc N/A N/A url N/A 2 // N/A N/A N/A netloc url N/A _splitnetloc url 2 N/A N/A allow_fragments N/A scheme uses_fragment N/A # url N/A N/A N/A url fragment N/A N/A url split # 1 N/A N/A N/A scheme uses_query N/A ? url N/A N/A N/A url query N/A N/A url split ? 1 N/A tuple N/A scheme netloc url query fragment N/A N/A _parse_cache N/A key tuple N/A tuple N/A urlunparse N/A N/A N/A scheme netloc url params query fragment N/A N/A N/A Put a parsed URL back together again.  This may result in a
    slightly different, but equivalent URL, if the URL that was parsed
    originally had redundant delimiters, e.g. a ? with an empty query
    (the draft states that these are equivalent). N/A params N/A N/A url N/A %s;%s N/A url params N/A N/A urlunsplit N/A scheme netloc url query fragment N/A urlunsplit N/A N/A N/A scheme netloc url query fragment N/A N/A N/A N/A netloc N/A scheme N/A scheme uses_netloc N/A N/A url N/A 2 // N/A N/A N/A url N/A N/A url N/A 1 / N/A N/A url N/A / url N/A url N/A N/A // N/A netloc url N/A scheme N/A N/A url N/A N/A scheme : url N/A query N/A N/A url N/A N/A url ? query N/A fragment N/A N/A url N/A N/A url # fragment N/A url N/A urljoin N/A N/A base url allow_fragments N/A 1 N/A N/A Join a base URL and a possibly relative URL to form an absolute
    interpretation of the latter. N/A N/A base N/A N/A url N/A N/A url N/A N/A base N/A N/A bscheme bnetloc bpath bparams bquery bfragment N/A urlparse base allow_fragments N/A N/A scheme netloc path params query fragment N/A urlparse url bscheme allow_fragments N/A N/A N/A scheme bscheme N/A scheme uses_relative N/A N/A url N/A N/A scheme uses_netloc N/A N/A netloc N/A N/A N/A urlunparse N/A scheme netloc path params query fragment N/A netloc bnetloc N/A N/A N/A path N/A 1 / N/A N/A N/A urlunparse N/A scheme netloc path params query fragment N/A N/A N/A path params query N/A N/A N/A urlunparse N/A scheme netloc bpath bparams bquery fragment N/A segments N/A N/A N/A N/A bpath split / N/A -1 N/A N/A path split / N/A N/A N/A segments N/A -1 . N/A N/A N/A segments N/A -1 N/A N/A . segments N/A N/A N/A N/A segments remove . N/A 1 N/A N/A i 1 N/A n N/A N/A len segments 1 N/A N/A i n N/A N/A N/A N/A N/A segments N/A i .. N/A N/A segments N/A N/A i 1 N/A .. N/A N/A N/A segments N/A N/A i 1 N/A i 1 N/A N/A i N/A i 1 N/A N/A N/A N/A segments N/A .. N/A N/A N/A segments N/A -1 N/A N/A N/A N/A N/A len segments 2 N/A N/A segments N/A -1 .. N/A N/A N/A segments N/A -2 N/A N/A N/A urlunparse N/A scheme netloc N/A N/A / join segments params query fragment N/A urldefrag N/A N/A url N/A N/A N/A Removes any existing fragment from URL.

    Returns a tuple of the defragmented URL and the fragment.  If
    the URL contained no fragments, the second element is the
    empty string.
     N/A N/A # url N/A N/A N/A s n p a q frag N/A urlparse url N/A defrag N/A urlunparse N/A s n p a q N/A N/A defrag frag N/A N/A N/A url N/A N/A test_input 
      http://a/b/c/d

      g:h        = <URL:g:h>
      http:g     = <URL:http://a/b/c/g>
      http:      = <URL:http://a/b/c/d>
      g          = <URL:http://a/b/c/g>
      ./g        = <URL:http://a/b/c/g>
      g/         = <URL:http://a/b/c/g/>
      /g         = <URL:http://a/g>
      //g        = <URL:http://g>
      ?y         = <URL:http://a/b/c/d?y>
      g?y        = <URL:http://a/b/c/g?y>
      g?y/./x    = <URL:http://a/b/c/g?y/./x>
      .          = <URL:http://a/b/c/>
      ./         = <URL:http://a/b/c/>
      ..         = <URL:http://a/b/>
      ../        = <URL:http://a/b/>
      ../g       = <URL:http://a/b/g>
      ../..      = <URL:http://a/>
      ../../g    = <URL:http://a/g>
      ../../../g = <URL:http://a/../g>
      ./../g     = <URL:http://a/b/g>
      ./g/.      = <URL:http://a/b/c/g/>
      /./g       = <URL:http://a/./g>
      g/./h      = <URL:http://a/b/c/g/h>
      g/../h     = <URL:http://a/b/c/h>
      http:g     = <URL:http://a/b/c/g>
      http:      = <URL:http://a/b/c/d>
      http:?y         = <URL:http://a/b/c/d?y>
      http:g?y        = <URL:http://a/b/c/g?y>
      http:g?y/./x    = <URL:http://a/b/c/g?y/./x>
 test N/A N/A N/A N/A N/A sys N/A base N/A N/A N/A sys argv N/A 1 N/A N/A fn N/A N/A sys argv N/A 1 N/A N/A fn - N/A N/A fp N/A sys stdin N/A N/A fp N/A open fn N/A N/A StringIO N/A fp N/A N/A StringIO StringIO test_input N/A 1 N/A N/A line N/A N/A fp readline N/A N/A line N/A N/A N/A words N/A N/A line split N/A N/A words N/A N/A N/A url N/A words N/A 0 N/A parts N/A urlparse url N/A N/A %-10s : %s N/A url parts N/A abs N/A urljoin base url N/A N/A base N/A N/A base abs N/A wrapped N/A <URL:%s> abs N/A N/A %-10s = %s N/A url wrapped N/A N/A N/A N/A len words 3 N/A N/A words N/A 1 = N/A N/A N/A wrapped N/A words N/A 2 N/A N/A EXPECTED N/A words N/A 2 !!!!!!!!!! N/A N/A N/A __name__ __main__ N/A N/A N/A test