def urldefragauth(url):
scheme, netloc, path, params, query, fragment = urlparse(url)<EOL>if not netloc:<EOL><INDENT>netloc, path = path, netloc<EOL><DEDENT>netloc = netloc.rsplit('<STR_LIT:@>', <NUM_LIT:1>)[-<NUM_LIT:1>]<EOL>return urlunparse((scheme, netloc, path, params, query, '<STR_LIT>'))<EOL>
Given a url remove the fragment and the authentication part