Skip to content

improve big query job error messages #12157

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conversation

bindermuehle
Copy link
Contributor

@bindermuehle bindermuehle commented Oct 27, 2024

  • add validation to check if project_id and dataset_id are set,
  • return descriptive error when the either variable is not set.

image

Fixes hashicorp/terraform-provider-google#19834

bigquery: added descriptive validation errors for missing required fields in `google_bigquery_job` destination table configuration

- add validation to check if project_id and dataset_id are set,
- return descriptive error when the either variable is not set.
Copy link

google-cla bot commented Oct 27, 2024

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

@github-actions github-actions bot requested a review from trodge October 27, 2024 19:14
Copy link

Hello! I am a robot. Tests will require approval from a repository maintainer to run.

@trodge, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look.

You can help make sure that review is quick by doing a self-review and by running impacted tests locally.

@modular-magician modular-magician added the awaiting-approval Pull requests that need reviewer's approval to run presubmit tests label Oct 27, 2024
make naming more exact
remove unecessary resources
fix issue with regex
@bindermuehle
Copy link
Contributor Author

Thanks for the input. I also had to fix the regex pattern, fixed it locally in the generated provider and didn't realize that I haven't moved the changes back to the magic module

Copy link
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.

Could you also update the screenshot now that the error message has been updated?

return transformed, nil
}
}
Copy link
Member

Choose a reason for hiding this comment

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

Remove unnecessary space?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

sorry about that. Too used to the auto formatter I suppose!

@modular-magician modular-magician added service/bigquery and removed awaiting-approval Pull requests that need reviewer's approval to run presubmit tests labels Oct 29, 2024
@modular-magician
Copy link
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 ( 2 files changed, 118 insertions(+))
google-beta provider: Diff ( 2 files changed, 118 insertions(+))
terraform-google-conversion: Diff ( 1 file changed, 57 insertions(+))

@modular-magician
Copy link
Collaborator

Tests analytics

Total tests: 122
Passed tests: 111
Skipped tests: 10
Affected tests: 1

Click here to see the affected service packages
  • bigquery

Action taken

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

Get to know how VCR tests work

@modular-magician
Copy link
Collaborator

🟢 Tests passed during RECORDING mode:
TestAccBigQueryJob_validationErrors [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

@trodge trodge merged commit 9323d5f into GoogleCloudPlatform:main Oct 29, 2024
13 checks passed
niharika-98 pushed a commit to niharika-98/magic-modules that referenced this pull request Nov 1, 2024
BBBmau pushed a commit to BBBmau/magic-modules that referenced this pull request Nov 5, 2024
akshat-jindal-nit pushed a commit to akshat-jindal-nit/magic-modules that referenced this pull request Nov 18, 2024
amanMahendroo pushed a commit to amanMahendroo/magic-modules that referenced this pull request Dec 17, 2024
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.

google_bigquery_job - required paramter missing (project_reference)
4 participants