def bom_stations(cache_dir):
 cache_file = os.path.join(cache_dir, '.bom-stations.json.gz')
 if (not os.path.isfile(cache_file)):
  stations = _get_bom_stations()
  with gzip.open(cache_file, 'wt') as cache:
   json.dump(stations, cache, sort_keys=True)
  return stations
 with gzip.open(cache_file, 'rt') as cache:
  return {k: tuple(v) for (k, v) in json.load(cache).items()}

def bom_stations ( cache_dir ) : cache_file = os . path . join ( cache_dir , '.bom-stations.json.gz' ) if ( not os . path . isfile ( cache_file ) ) : stations = _get_bom_stations ( ) with gzip . open ( cache_file , 'wt' ) as cache : json . dump ( stations , cache , sort_keys = True ) return stations with gzip . open ( cache_file , 'rt' ) as cache : return { k : tuple ( v ) for ( k , v ) in json . load ( cache ) . items ( ) }
return {conf_station: } for all stations .