def get_base_path(base):
 base_parsed = urlparse(base)
 if (not base_parsed.path):
  sub_path = u''
 else:
  sub_path = base_parsed.path
 if sub_path.endswith(u'/'):
  return sub_path
 else:
  return (sub_path + u'/')

def get_base_path ( base ) : base_parsed = urlparse ( base ) if ( not base_parsed . path ) : sub_path = u'' else : sub_path = base_parsed . path if sub_path . endswith ( u'/' ) : return sub_path else : return ( sub_path + u'/' )
get absolute path to resource .