swh.web.browse.browseurls module

class swh.web.browse.browseurls.BrowseUrls[source]

Bases: swh.web.common.urlsindex.UrlsIndex

Class to manage swh-web browse application urls.

scope = 'browse'
swh.web.browse.browseurls.browse_route(*url_patterns, view_name=None, checksum_args=None)[source]

Decorator to ease the registration of a swh-web browse endpoint

  • url_patterns – list of url patterns used by Django to identify the browse routes

  • view_name – the name of the Django view associated to the routes used to reverse the url