diff --git a/docs/cli/use.rst b/docs/cli/use.rst index d62f285..c8008e5 100644 --- a/docs/cli/use.rst +++ b/docs/cli/use.rst @@ -83,13 +83,13 @@ Use this option if: Create array of all paths for each row in each summary table ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -The ``--field_lists`` option adds a new field to each summary table called ``field_list`` which contains an array of all JSON paths (excluding index postiions) contained in the object that the row represents. So for example in the ``awards_summary`` table it will contain the paths of every ``award`` object. +The ``--field_lists`` option adds a ``field_list`` column to each summary table, which contains a JSON array of all JSON paths (excluding array indices) in the object that the row describes. For example, a ``field_list`` value in the ``awards_summary`` table will contain the JSON paths in an award object. .. code-block:: bash ./manage.py add 123 "The note" --field-lists -This can be useful when asking questions about the existance of multiple child fields in a simple way. For example, if you want to know how many awards have at least one ``document`` whith an ``id`` and at least one ``item`` with an ``id``, you could run the following. +This can be used to check for the presence of multiple fields. For example, to count the number of awards that have at least one document with an ``id`` and at least one item with an ``id``, run: ``` @@ -97,7 +97,7 @@ This can be useful when asking questions about the existance of multiple child f SELECT count(*) FROM view_data_collection_1.awards_summary WHERE field_list @> '{documents/id, items/id}'; -The ``@>`` symbol stands for 'contains' and the right hand argument is a string representation of an array. +The ``@>`` operator tests whether the left ARRAY value contains the right ARRAY values. .. _remove: diff --git a/docs/definitions/award_documents_summary.csv b/docs/definitions/award_documents_summary.csv index 119b6a6..b7085f9 100644 --- a/docs/definitions/award_documents_summary.csv +++ b/docs/definitions/award_documents_summary.csv @@ -10,4 +10,4 @@ data_id,integer,"id for the ""data"" table in Kingfisher that holds the original document,jsonb,JSONB of the document documenttype,text,`documentType` field from the document object format,text,`format` field from the document object -field_list,ARRAY,Array of paths for the document object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the document object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/award_items_summary.csv b/docs/definitions/award_items_summary.csv index cedb0d9..80813c6 100644 --- a/docs/definitions/award_items_summary.csv +++ b/docs/definitions/award_items_summary.csv @@ -15,4 +15,4 @@ unit_currency,text,`currency` from the unit/value object item_classification,text,Concatenation of classification/scheme and classification/id item_additionalidentifiers_ids,jsonb,JSONB list of the concatenation of additionalClassification/scheme and additionalClassification/id additional_classification_count,integer,Count of additional classifications -field_list,ARRAY,Array of paths for the item object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the item object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/award_suppliers_summary.csv b/docs/definitions/award_suppliers_summary.csv index 8feb76c..f4757ad 100644 --- a/docs/definitions/award_suppliers_summary.csv +++ b/docs/definitions/award_suppliers_summary.csv @@ -16,4 +16,4 @@ supplier_additionalidentifiers_count,integer,Count of additional identifiers link_to_parties,integer,"Does this buyer link to a party in the parties array using the `id` field from buyer object linking to the `id` field in a party object? If this is true then 1, otherwise 0" link_with_role,integer,If there is a link does the parties object have `suppliers` in its roles list? If it does then 1 otherwise 0 party_index,bigint,Position of the party in the parties array -field_list,ARRAY,Array of paths for the supplier object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the supplier object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/awards_summary.csv b/docs/definitions/awards_summary.csv index e215bca..4edebf7 100644 --- a/docs/definitions/awards_summary.csv +++ b/docs/definitions/awards_summary.csv @@ -22,4 +22,4 @@ documents_count,bigint,Number of documents in documents array documenttype_counts,jsonb,JSONB object with the keys as unique documentTypes and the values as count of the appearances of that `documentType` in the `documents` array items_count,bigint,Count of items award,jsonb,JSONB of award object -field_list,ARRAY,Array of paths for the award object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the award object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/buyer_summary.csv b/docs/definitions/buyer_summary.csv index b80e402..72c2b20 100644 --- a/docs/definitions/buyer_summary.csv +++ b/docs/definitions/buyer_summary.csv @@ -15,4 +15,4 @@ buyer_additionalidentifiers_count,integer,Count of additional identifiers link_to_parties,integer,"Does this buyer link to a party in the parties array using the `id` field from buyer object linking to the `id` field in a party object? If this is true then 1, otherwise 0" link_with_role,integer,If there is a link does the parties object have `buyer` in its roles list? If it does then 1 otherwise 0 party_index,bigint,If there is a link what is the index of the party in the `parties` array then this can be used for joining to the `parties_summary` table -field_list,ARRAY,Array of paths for the buyer object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the buyer object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/contract_documents_summary.csv b/docs/definitions/contract_documents_summary.csv index 213fc39..bffa8fd 100644 --- a/docs/definitions/contract_documents_summary.csv +++ b/docs/definitions/contract_documents_summary.csv @@ -10,4 +10,4 @@ data_id,integer,"id for the ""data"" table in Kingfisher that holds the original document,jsonb,JSONB of the document documenttype,text,`documentType` field from the document object format,text,`format` field from the document object -field_list,ARRAY,Array of paths for the document object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the document object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/contract_implementation_documents_summary.csv b/docs/definitions/contract_implementation_documents_summary.csv index 213fc39..bffa8fd 100644 --- a/docs/definitions/contract_implementation_documents_summary.csv +++ b/docs/definitions/contract_implementation_documents_summary.csv @@ -10,4 +10,4 @@ data_id,integer,"id for the ""data"" table in Kingfisher that holds the original document,jsonb,JSONB of the document documenttype,text,`documentType` field from the document object format,text,`format` field from the document object -field_list,ARRAY,Array of paths for the document object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the document object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/contract_implementation_milestones_summary.csv b/docs/definitions/contract_implementation_milestones_summary.csv index c7f331f..7c10d7f 100644 --- a/docs/definitions/contract_implementation_milestones_summary.csv +++ b/docs/definitions/contract_implementation_milestones_summary.csv @@ -11,4 +11,4 @@ milestone,jsonb,JSONB of milestone object type,text,`type` from milestone object code,text,`code` from milestone object status,text,`status` from milestone object -field_list,ARRAY,Array of paths for the milestone object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the milestone object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/contract_implementation_transactions_summary.csv b/docs/definitions/contract_implementation_transactions_summary.csv index 24f9388..5982210 100644 --- a/docs/definitions/contract_implementation_transactions_summary.csv +++ b/docs/definitions/contract_implementation_transactions_summary.csv @@ -10,4 +10,4 @@ data_id,integer,"id for the ""data"" table in Kingfisher that holds the original transaction_amount,numeric,`amount` field from the value object or the deprecated amount object transaction_currency,text,`currency` field from the value object or the deprecated amount object transaction,jsonb,JSONB of transaction object -field_list,ARRAY,Array of paths for the transaction object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the transaction object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/contract_items_summary.csv b/docs/definitions/contract_items_summary.csv index 2b3e455..069636d 100644 --- a/docs/definitions/contract_items_summary.csv +++ b/docs/definitions/contract_items_summary.csv @@ -15,4 +15,4 @@ unit_currency,text,`currency` from the unit/value object item_classification,text,Concatenation of classification/scheme and classification/id item_additionalidentifiers_ids,jsonb,JSONB list of the concatenation of additionalClassification/scheme and additionalClassification/id additional_classification_count,integer,Count of additional classifications -field_list,ARRAY,Array of paths for the item object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the item object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/contract_milestones_summary.csv b/docs/definitions/contract_milestones_summary.csv index c7f331f..7c10d7f 100644 --- a/docs/definitions/contract_milestones_summary.csv +++ b/docs/definitions/contract_milestones_summary.csv @@ -11,4 +11,4 @@ milestone,jsonb,JSONB of milestone object type,text,`type` from milestone object code,text,`code` from milestone object status,text,`status` from milestone object -field_list,ARRAY,Array of paths for the milestone object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the milestone object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/contracts_summary.csv b/docs/definitions/contracts_summary.csv index 7c56855..9467e3b 100644 --- a/docs/definitions/contracts_summary.csv +++ b/docs/definitions/contracts_summary.csv @@ -29,4 +29,4 @@ implementation_documenttype_counts,jsonb,JSONB object with the keys as unique do implementation_milestones_count,bigint,Number of documents in documents array implementation_milestonetype_counts,jsonb,JSONB object with the keys as unique milestoneTypes and the values as count of the appearances of that `milestoneType` in the `milestone` array contract,jsonb,JSONB of contract object -field_list,ARRAY,Array of paths for the contract object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the contract object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/parties_summary.csv b/docs/definitions/parties_summary.csv index e3efb62..dfabb4d 100644 --- a/docs/definitions/parties_summary.csv +++ b/docs/definitions/parties_summary.csv @@ -13,4 +13,4 @@ unique_identifier_attempt,text,"The `id` from party object if it exists, otherwi parties_additionalidentifiers_ids,jsonb,JSONB list of the concatenation of scheme and id of all additionalIdentifier objects parties_additionalidentifiers_count,integer,Count of additional identifiers party,jsonb,JSONB of party object -field_list,ARRAY,Array of paths for the party object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the party object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/planning_documents_summary.csv b/docs/definitions/planning_documents_summary.csv index ba16f95..1f14f9b 100644 --- a/docs/definitions/planning_documents_summary.csv +++ b/docs/definitions/planning_documents_summary.csv @@ -9,4 +9,4 @@ data_id,integer,"id for the ""data"" table in Kingfisher that holds the original document,jsonb,JSONB of the document documenttype,text,`documentType` field from the document object format,text,`format` field from the document object -field_list,ARRAY,Array of paths for the document object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the document object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/planning_milestones_summary.csv b/docs/definitions/planning_milestones_summary.csv index f76634c..787d8fd 100644 --- a/docs/definitions/planning_milestones_summary.csv +++ b/docs/definitions/planning_milestones_summary.csv @@ -10,4 +10,4 @@ milestone,jsonb,JSONB of milestone object type,text,`type` from milestone object code,text,`code` from milestone object status,text,`status` from milestone object -field_list,ARRAY,Array of paths for the milestone object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the milestone object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/planning_summary.csv b/docs/definitions/planning_summary.csv index 12b9a72..60707e1 100644 --- a/docs/definitions/planning_summary.csv +++ b/docs/definitions/planning_summary.csv @@ -13,4 +13,4 @@ documenttype_counts,jsonb,JSONB object with the keys as unique documentTypes and milestones_count,bigint,Count of milestones milestonetype_counts,jsonb,JSONB object with the keys as unique milestoneTypes and the values as a count of the appearances of that `milestoneType` in the `milestones` array planning,jsonb,JSONB of planning object -field_list,ARRAY,Array of paths for the planning object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the planning object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/procuringEntity_summary.csv b/docs/definitions/procuringEntity_summary.csv index 8700539..b2796e8 100644 --- a/docs/definitions/procuringEntity_summary.csv +++ b/docs/definitions/procuringEntity_summary.csv @@ -14,4 +14,4 @@ procuringentity_additionalidentifiers_count,integer,Count of additional identifi link_to_parties,integer,"Does this procuringEntity link to a party in the parties array using the `id` field from buyer object linking to the `id` field in a party object? If this is true then 1, otherwise 0" link_with_role,integer,If there is a link does the parties object have `procuringEntity` in its roles list? If it does then 1 otherwise 0 party_index,bigint,If there is a link what is the index of the party in the `parties` array then this can be used for joining to the `parties_summary` table -field_list,ARRAY,Array of paths for the procuringentity object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the procuringentity object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/release_summary.csv b/docs/definitions/release_summary.csv index 31099d8..8c0b04b 100644 --- a/docs/definitions/release_summary.csv +++ b/docs/definitions/release_summary.csv @@ -59,4 +59,4 @@ release_check,jsonb,JSONB of Data Review Tool output which includes validation e release_check11,jsonb,JSONB of Data Review Tool output run against 1.1 version of OCDS even if the data is from 1.0 record_check,jsonb,JSONB of Data Review Tool output which includes validation errors and additional field information record_check11,jsonb,JSONB of Data Review Tool output run against 1.1 version of OCDS even if the data is from 1.0 -field_list,ARRAY,Array of paths for the release object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the release object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/tender_documents_summary.csv b/docs/definitions/tender_documents_summary.csv index ba16f95..1f14f9b 100644 --- a/docs/definitions/tender_documents_summary.csv +++ b/docs/definitions/tender_documents_summary.csv @@ -9,4 +9,4 @@ data_id,integer,"id for the ""data"" table in Kingfisher that holds the original document,jsonb,JSONB of the document documenttype,text,`documentType` field from the document object format,text,`format` field from the document object -field_list,ARRAY,Array of paths for the document object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the document object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/tender_items_summary.csv b/docs/definitions/tender_items_summary.csv index dcb0d9b..dfc0bac 100644 --- a/docs/definitions/tender_items_summary.csv +++ b/docs/definitions/tender_items_summary.csv @@ -14,4 +14,4 @@ unit_currency,text,`currency` from the unit/value object item_classification,text,Concatenation of classification/scheme and classification/id item_additionalidentifiers_ids,jsonb,JSONB list of the concatenation of additionalClassification/scheme and additionalClassification/id additional_classification_count,integer,Count of additional classifications -field_list,ARRAY,Array of paths for the item object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the item object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/tender_milestones_summary.csv b/docs/definitions/tender_milestones_summary.csv index f76634c..787d8fd 100644 --- a/docs/definitions/tender_milestones_summary.csv +++ b/docs/definitions/tender_milestones_summary.csv @@ -10,4 +10,4 @@ milestone,jsonb,JSONB of milestone object type,text,`type` from milestone object code,text,`code` from milestone object status,text,`status` from milestone object -field_list,ARRAY,Array of paths for the milestone object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the milestone object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/tender_summary.csv b/docs/definitions/tender_summary.csv index 76ef505..1485cc6 100644 --- a/docs/definitions/tender_summary.csv +++ b/docs/definitions/tender_summary.csv @@ -44,4 +44,4 @@ milestones_count,bigint,Count of milestones milestonetype_counts,jsonb,JSONB object with the keys as unique milestoneTypes and the values as a count of the appearances of that `milestoneType` in the `milestones` array items_count,bigint,Count of items tender,jsonb,JSONB of tender object -field_list,ARRAY,Array of paths for the tender object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the tender object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/docs/definitions/tenderers_summary.csv b/docs/definitions/tenderers_summary.csv index 9f671c8..725fdd7 100644 --- a/docs/definitions/tenderers_summary.csv +++ b/docs/definitions/tenderers_summary.csv @@ -15,4 +15,4 @@ tenderer_additionalidentifiers_count,integer,Count of additional identifiers link_to_parties,integer,"Does this tenderer link to a party in the parties array using the `id` field from buyer object linking to the `id` field in a party object? If this is true then 1, otherwise 0" link_with_role,integer,If there is a link does the parties object have `tenderers` in its roles list? If it does then 1 otherwise 0 party_index,bigint,If there is a link what is the index of the party in the `parties` array. This can be used for joining to the `parties_summary` table -field_list,ARRAY,Array of paths for the tenderer object. Paths excluding index numbers for arrays.This field will only appear if --field-lists option is specified +field_list,ARRAY,"Array of JSON paths in the tenderer object, excluding array indices.This column is only available if the --field-lists option was used." diff --git a/manage.py b/manage.py index 1fcc5e6..58dc7b3 100755 --- a/manage.py +++ b/manage.py @@ -24,13 +24,13 @@ flags = re.MULTILINE | re.IGNORECASE basedir = os.path.dirname(os.path.realpath(__file__)) -SummaryTable = namedtuple("SummaryTable", "name primary_keys data_field is_table") +SummaryTable = namedtuple('SummaryTable', 'name primary_keys data_field is_table') SUMMARY_TABLES = [ SummaryTable('award_documents_summary', 'id, award_index, document_index', 'document', True), SummaryTable('award_items_summary', 'id, award_index, item_index', 'item', True), SummaryTable('award_suppliers_summary', 'id, award_index, supplier_index', 'supplier', True), - SummaryTable('awards_summary', 'id, award_index', "award", False), + SummaryTable('awards_summary', 'id, award_index', 'award', False), SummaryTable('buyer_summary', 'id', 'buyer', True), SummaryTable('contract_documents_summary', 'id, contract_index, document_index', 'document', True), SummaryTable('contract_implementation_documents_summary', @@ -41,17 +41,17 @@ 'id, contract_index, transaction_index', 'transaction', True), SummaryTable('contract_items_summary', 'id, contract_index, item_index', 'item', True), SummaryTable('contract_milestones_summary', 'id, contract_index, milestone_index', 'milestone', True), - SummaryTable('contracts_summary', 'id, contract_index', "contract", False), - SummaryTable('parties_summary', 'id, party_index', "party", False), + SummaryTable('contracts_summary', 'id, contract_index', 'contract', False), + SummaryTable('parties_summary', 'id, party_index', 'party', False), SummaryTable('planning_documents_summary', 'id, document_index', 'document', True), SummaryTable('planning_milestones_summary', 'id, milestone_index', 'milestone', True), SummaryTable('planning_summary', 'id', 'planning', False), SummaryTable('procuringentity_summary', 'id', 'procuringentity', True), - SummaryTable('release_summary', 'id', "release", False), + SummaryTable('release_summary', 'id', 'release', False), SummaryTable('tender_documents_summary', 'id', 'document', True), SummaryTable('tender_items_summary', 'id, item_index', 'item', True), SummaryTable('tender_milestones_summary', 'id, milestone_index', 'milestone', True), - SummaryTable('tender_summary', 'id', "tender", False), + SummaryTable('tender_summary', 'id', 'tender', False), SummaryTable('tenderers_summary', 'id, tenderer_index', 'tenderer', True), ] @@ -241,7 +241,7 @@ def install(): @click.option('--field-counts/--no-field-counts', 'field_counts_option', default=True, help="Whether to create the field_counts table (default true).") @click.option('--field-lists/--no-field-lists', 'field_lists_option', default=False, - help="Whether to create the field_lists column to all summary tables (default false).") + help="Whether to add a field_list column to all summary tables (default false).") @click.pass_context def add(ctx, collections, note, name, tables_only, field_counts_option, field_lists_option): """ @@ -510,7 +510,7 @@ def correct_user_permissions(): db.commit() -def _create_field_list_field(summary_table, tables_only): +def _add_field_list_column(summary_table, tables_only): if tables_only or summary_table.is_table: relation_type = "TABLE" @@ -545,7 +545,7 @@ def _create_field_list_field(summary_table, tables_only): """) -def _comments_on_field_list_views(summary_table, name): +def _add_field_list_comments(summary_table, name): statement = """ SELECT @@ -558,17 +558,17 @@ def _comments_on_field_list_views(summary_table, name): table_schema = %(schema)s AND LOWER(isc.table_name) = LOWER(%(table)s) """ - for row in db.all(statement, {'schema': name, 'table': summary_table.name + '_no_field_list'}): + for row in db.all(statement, {'schema': name, 'table': f'{summary_table.name}_no_field_list'}): db.execute(f'COMMENT ON COLUMN {summary_table.name}.{row[0]} IS %(comment)s', {'comment': row[1]}) - comment = (f'Array of paths for the {summary_table.data_field} object. Paths excluding index numbers for arrays.' - f'This field will only appear if --field-lists option is specified') + comment = (f'Array of JSON paths in the {summary_table.data_field} object, excluding array indices. ' + f'This column is only available if the --field-lists option was used.') db.execute(f'COMMENT ON COLUMN {summary_table.name}.field_list IS %(comment)s', {'comment': comment}) def field_lists(name, tables_only=False): """ - Creates the field_lists field on all summary tables. + Adds the field_list column on all summary tables. :param str name: the last part of a schema's name after "view_data_" :param bool tables_only: whether to create SQL tables instead of SQL views @@ -580,8 +580,8 @@ def field_lists(name, tables_only=False): start = time() for summary_table in SUMMARY_TABLES: - _create_field_list_field(summary_table, tables_only) - _comments_on_field_list_views(summary_table, name) + _add_field_list_column(summary_table, tables_only) + _add_field_list_comments(summary_table, name) logger.info('Total time: %ss', time() - start)