From 577debb433af3984454ae1f29ffa0c005073cb5d Mon Sep 17 00:00:00 2001 From: Jorge Gallegos Date: Fri, 27 Jun 2025 12:10:15 -0600 Subject: [PATCH] According to docs, these fields are all mandatory If you specify table_reference, you should specify all 3 fields as per docs https://cloud.google.com/bigquery/docs/reference/rest/v2/TableReference --- plugins/modules/gcp_bigquery_table.py | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/plugins/modules/gcp_bigquery_table.py b/plugins/modules/gcp_bigquery_table.py index 0eaebb1d..ac529cf1 100644 --- a/plugins/modules/gcp_bigquery_table.py +++ b/plugins/modules/gcp_bigquery_table.py @@ -56,17 +56,17 @@ options: dataset_id: description: - The ID of the dataset containing this table. - required: false + required: true type: str project_id: description: - The ID of the project containing this table. - required: false + required: true type: str table_id: description: - The ID of the the table. - required: false + required: true type: str clustering: description: @@ -1016,7 +1016,11 @@ def main(): module = GcpModule( argument_spec=dict( state=dict(default='present', choices=['present', 'absent'], type='str'), - table_reference=dict(type='dict', options=dict(dataset_id=dict(type='str'), project_id=dict(type='str'), table_id=dict(type='str'))), + table_reference=dict(type='dict', options=dict( + dataset_id=dict(type='str', required=True), + project_id=dict(type='str', required=True), + table_id=dict(type='str', required=True) + )), clustering=dict(type='list', elements='str'), description=dict(type='str'), friendly_name=dict(type='str'),