def split_auth_from_netloc(netloc):
if '<STR_LIT:@>' not in netloc:<EOL><INDENT>return netloc, (None, None)<EOL><DEDENT>auth, netloc = netloc.rsplit('<STR_LIT:@>', <NUM_LIT:1>)<EOL>if '<STR_LIT::>' in auth:<EOL><INDENT>user_pass = auth.split('<STR_LIT::>', <NUM_LIT:1>)<EOL><DEDENT>else:<EOL><INDENT>user_pass = auth, None<EOL><DEDENT>user_pass = tuple(<EOL>None if x is None else urllib_unquote(x) for x in user_pass<EOL>)<EOL>return netloc, user_pass<EOL>
Parse out and remove the auth information from a netloc.

Returns: (netloc, (username, password)).