Skip to content

biguery: Fix Table does not have Schema failures in Tests#16517

Merged
BBBmau merged 1 commit into
GoogleCloudPlatform:mainfrom
BBBmau:fix-accessPolicy-table-test
Mar 4, 2026
Merged

biguery: Fix Table does not have Schema failures in Tests#16517
BBBmau merged 1 commit into
GoogleCloudPlatform:mainfrom
BBBmau:fix-accessPolicy-table-test

Conversation

@BBBmau
Copy link
Copy Markdown
Collaborator

@BBBmau BBBmau commented Feb 24, 2026

Fixes hashicorp/terraform-provider-google#26111
Fixes hashicorp/terraform-provider-google#26115

This may be a temporary fix as it remains unclear why the tests began to fail in the first place. From my initial investigation comment:

This error comes from bigquery_table with the following error:

    resource_bigquery_row_access_policy_test.go:33: Step 1/4 error: Error running apply: exit status 1
        
        Error: Error creating RowAccessPolicy: googleapi: Error 400: Table hc-terraform-testing.tf_test_dataset_idb8yjhx3nlr.tf_test_table_idb8yjhx3nlr does not have a schema.
        
          with google_bigquery_row_access_policy.test,
          on terraform_plugin_test.tf line 14, in resource "google_bigquery_row_access_policy" "test":
          14: resource "google_bigquery_row_access_policy" "test" {

initially thought this was from a go.mod bump as

introduced cloud.golang bump where the first failure began. This doesn't seem like the cause as when I revert the bump we still run into the same issue

TeamCity Build:
https://hashicorp.teamcity.com/test/5962285105755560780?currentProjectId=TerraformProviders_GoogleCloud_GOOGLE_NIGHTLYTESTS

Release Note Template for Downstream PRs (will be copied)

See Write release notes for guidance.


@modular-magician
Copy link
Copy Markdown
Collaborator

Hi there, I'm the Modular magician. I've detected the following information about your changes:

Diff report

Your PR generated some diffs in downstreams - here they are.

google provider: Diff ( 3 files changed, 36 insertions(+))
google-beta provider: Diff ( 3 files changed, 36 insertions(+))
Open in Cloud Shell: Diff ( 1 file changed, 9 insertions(+))

@modular-magician
Copy link
Copy Markdown
Collaborator

Tests analytics

Total tests: 150
Passed tests: 138
Skipped tests: 10
Affected tests: 2

Click here to see the affected service packages
  • bigquery

Action taken

Found 2 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
  • TestAccBigQueryRowAccessPolicy_bigqueryRowAccessPolicyBasicExample
  • TestAccBigQueryRowAccessPolicy_update

Get to know how VCR tests work

@modular-magician
Copy link
Copy Markdown
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccBigQueryRowAccessPolicy_bigqueryRowAccessPolicyBasicExample [Debug log]
TestAccBigQueryRowAccessPolicy_update [Debug log]

🟢 No issues found for passed tests after REPLAYING rerun.


🟢 All tests passed!

View the build log or the debug log for each test

Copy link
Copy Markdown
Member

@wj-chen wj-chen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the fix. Looks to be an API validation update that now enforces that base table for the row access policy must have a schema.

@BBBmau BBBmau requested a review from melinath March 4, 2026 00:00
@BBBmau BBBmau added this pull request to the merge queue Mar 4, 2026
Merged via the queue into GoogleCloudPlatform:main with commit ccb380e Mar 4, 2026
22 checks passed
@BBBmau BBBmau deleted the fix-accessPolicy-table-test branch March 4, 2026 00:31
aditikumarii-google pushed a commit to aditikumarii-google/magic-modules that referenced this pull request Mar 10, 2026
ChuAmberZhang pushed a commit to ChuAmberZhang/magic-modules that referenced this pull request Apr 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Failing test(s): TestAccBigQueryRowAccessPolicy_bigqueryRowAccessPolicyBasicExample Failing test(s): TestAccBigQueryRowAccessPolicy_update

4 participants