pyrcs.updater.fetch_site_map

pyrcs.updater.fetch_site_map(update=False, confirmation_required=True, verbose=False)[source]

Fetch the site map from the package data.

Parameters
  • update (bool) – whether to check on update and proceed to update the package data, defaults to False

  • confirmation_required (bool) – whether to prompt a message for confirmation to proceed, defaults to True

  • verbose (bool, int) – whether to print relevant information in console as the function runs, defaults to False

Returns

dictionary of site map data

Return type

dict

Examples:

>>> from pyrcs.updater import fetch_site_map

>>> site_map_dat = fetch_site_map()

>>> type(site_map_dat)
<class 'dict'>
>>> print(site_map_dat['Home'])
http://www.railwaycodes.org.uk/index.shtml