#NEWLINE# @ property #NEWLINE# def filename( self ) : #NEWLINE# #INDENT# ( _ , netloc , path , _ , _ ) = urlparse . urlsplit ( self . url ) #NEWLINE# name = ( posixpath . basename ( path . rstrip ( '/' ) ) or netloc ) #NEWLINE# assert name , ( 'URL %r produced no filename' % self . url ) #NEWLINE# return name