9.1.2.17. GeoHealthCheck.util

9.1.2.17.1. Module Contents

9.1.2.17.1.1. Functions

average(values)

calculates average from a list

format_checked_datetime(run[, default])

common formatting datetime fields

format_run_status(run[, default])

common formatting success boolean field

format_obj_value(obj[, default])

common formatting object field

create_hash(string)

verify_hash(hash1, hash2)

percentage(number, total)

calculates a percentage

get_python_snippet(resource)

return sample interactive session

render_template2(template, template_vars)

convenience function to render template in a non-Flask context

send_email(mail_config, fromaddr, toaddr, msg)

convenience function to send an email

geocode(value[, spatial_keyword_type])

convenience function to geocode a value

transform_bbox(epsg1, epsg2, bbox)

convenience function to transform a bbox array

read(filename[, encoding])

read file contents

encode(key, string)

decode(→ str)

create_requests_retry_session([retries, ...])

expand_url(url, query_clause)

9.1.2.17.1.2. Attributes

APP

CONFIG

LOGGER

GeoHealthCheck.util.APP
GeoHealthCheck.util.CONFIG
GeoHealthCheck.util.LOGGER
GeoHealthCheck.util.average(values)

calculates average from a list

GeoHealthCheck.util.format_checked_datetime(run, default='-')

common formatting datetime fields

GeoHealthCheck.util.format_run_status(run, default='-')

common formatting success boolean field

GeoHealthCheck.util.format_obj_value(obj, default='-')

common formatting object field

GeoHealthCheck.util.create_hash(string)
GeoHealthCheck.util.verify_hash(hash1, hash2)
GeoHealthCheck.util.percentage(number, total)

calculates a percentage

GeoHealthCheck.util.get_python_snippet(resource)

return sample interactive session

GeoHealthCheck.util.render_template2(template, template_vars)

convenience function to render template in a non-Flask context

GeoHealthCheck.util.send_email(mail_config, fromaddr, toaddr, msg)

convenience function to send an email

GeoHealthCheck.util.geocode(value, spatial_keyword_type='hostname')

convenience function to geocode a value

GeoHealthCheck.util.transform_bbox(epsg1, epsg2, bbox)

convenience function to transform a bbox array

GeoHealthCheck.util.read(filename, encoding='utf-8')

read file contents

GeoHealthCheck.util.encode(key, string)
GeoHealthCheck.util.decode(key: str, string: str) str
GeoHealthCheck.util.create_requests_retry_session(retries=3, backoff_factor=0.3, status_forcelist=(500, 502, 504), session=None)
GeoHealthCheck.util.expand_url(url, query_clause)