From 40ba28375552ed4c527075ef85ecd8d17ca8f86c Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Mon, 9 Jan 2023 10:00:26 +0000 Subject: [PATCH] Comments --- session.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/session.py b/session.py index f71df18d3..f60522444 100644 --- a/session.py +++ b/session.py @@ -21,6 +21,8 @@ from http.client import HTTPConnection def create_session(proxy_type: str): + """ Creates a new session + """ session = None try: session = requests.session() @@ -226,6 +228,8 @@ def get_json(signing_priv_key_pem: str, version: str = __version__, http_prefix: str = 'https', domain: str = 'testdomain', timeout_sec: int = 20, quiet: bool = False) -> {}: + """Download some json + """ if not isinstance(url, str): if debug and not quiet: print('url: ' + str(url)) @@ -263,6 +267,8 @@ def get_vcard(xml_format: bool, session, url: str, params: {}, debug: bool, version: str, http_prefix: str, domain: str, timeout_sec: int = 20, quiet: bool = False) -> {}: + """Download a vcard + """ if not isinstance(url, str): if debug and not quiet: print('url: ' + str(url)) @@ -341,6 +347,8 @@ def download_html(signing_priv_key_pem: str, session, url: str, headers: {}, params: {}, debug: bool, version: str, http_prefix: str, domain: str, timeout_sec: int = 20, quiet: bool = False) -> {}: + """Download a html document + """ if not isinstance(url, str): if debug and not quiet: print('url: ' + str(url)) @@ -473,6 +481,8 @@ def download_ssml(signing_priv_key_pem: str, session, url: str, headers: {}, params: {}, debug: bool, version: str, http_prefix: str, domain: str, timeout_sec: int = 20, quiet: bool = False) -> {}: + """Download a ssml document + """ if not isinstance(url, str): if debug and not quiet: print('url: ' + str(url))