-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Fix import issue for Dataplex Datascan #8578
Conversation
Hello! I am a robot. It looks like you are a community contributor. @hao-nan-li, 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. |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Breaking Change(s) DetectedThe following breaking change(s) were detected within your pull request.
If you believe this detection to be incorrect please raise the concern with your reviewer. If you intend to make this change you will need to wait for a major release window. An Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 1 file changed, 14 insertions(+), 11 deletions(-)) |
@hao-nan-li This is just a change in one of our output only fields. (edited: didn't mean for this to be in bold :)) I don't actually think the Result message as a whole is useful for Terraform at all. If we want to just ignore the entire message, can we just choose not to specify the message in the YAML file? For context, dataProfileResult shows the result of the latest Job run under a DataScan definition. I don't think this is ever useful in a Terraform context at all. |
Tests analyticsTotal tests:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the explanation. Looks like this field is not marked as an output only field, so I may still consider it as a breaking-change.
We are currently preparing for a major release, breaking changes are accepted following these instructions https://googlecloudplatform.github.io/magic-modules/develop/make-a-breaking-change/#contributing-to-the-next-major-release-500.
In line 644, we mark the parent message as output: true. Wouldn't that apply to all inner nested fields and messages? |
Sorry I missed the part from the parent. On the other hand, could you take a quick look at https://googlecloudplatform.github.io/magic-modules/develop/make-a-breaking-change/#what-counts-as-a-breaking-change? Changing the output format of a field is part of it. |
Ahh, okay, i'm comfortable modifying my PR and waiting for it to be released with the next major version. Let me update that by end-of-day One question I have is, if I don't believe the message is ever useful, can I simply remove the entire parent message (name: 'dataProfileResult') entirely from the YAML spec? I'm aware that this would also be a breaking change, I'd just rather keep the YAML spec simple where I can. |
For us, not having output:true field in the yaml file is always an option. Note that you can create PRs with breaking-change. Just need to merge it against the 5.0.0 major release branch. https://googlecloudplatform.github.io/magic-modules/develop/make-a-breaking-change/#contributing-to-the-next-major-release-500 |
Thanks for the confirmation. I've created a fresh pull request targeting the next major release. |
@hao-nan-li @c2thorn Given that we have a customer blocked on us fixing this, I'd like to check again whether the fix in this PR should really be considered a breaking change. Anyone currently trying to import a Dataprofile datascan would just run into TF crashing, i.e. they would not have any state in a different format like typical field format changes. There should not be any risk of incompatible states / formats stored anywhere. I understand the general guidance around field format changes, but in this case:
To be clear, in this PR, I'd like to do the minimal change to unblock existing users. The larger change of removing dataprofileresult and dataqualityresult entirely is definitely safer to do in a new major version. For additional context: #8583 (comment) |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Breaking Change(s) DetectedThe following breaking change(s) were detected within your pull request.
If you believe this detection to be incorrect please raise the concern with your reviewer. If you intend to make this change you will need to wait for a major release window. An Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 1 file changed, 14 insertions(+), 11 deletions(-)) |
Tests analyticsTotal tests:
|
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR hasn't generated any diffs, but I'll let you know if a future commit does. |
@saurabh-net Looks like The YAML looks like /~https://github.com/GoogleCloudPlatform/magic-modules/blob/main/mmv1/products/vertexai/Index.yaml#L110 This should be helpful as the crash was in the generated flattener. |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 1 file changed, 2 insertions(+), 20 deletions(-)) |
Looks like the custom flatten did the trick :) (based on the diff) |
great, let us know when you have been able to give a manual test a try. @hao-nan-li I can take over this PR at this point |
Thanks! |
Tests analyticsTotal tests:
|
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are. Terraform GA: Diff ( 1 file changed, 2 insertions(+), 362 deletions(-)) |
Ouch, looks like this affects all terraform operations (plan / apply) for Profile Datascans with any jobs created for them. I locally tested it, and there were a few other fields which are incorrectly specified. With that, it is working fine locally. |
Tests analyticsTotal tests:
|
Fix import issue for Datascan Dataprofile scans with existing jobs.
The TopN value message was incorrectly encoded as a map instead of as a array.
If this PR is for Terraform, I acknowledge that I have:
make test
andmake lint
in the generated providers to ensure it passes unit and linter tests.Release Note Template for Downstream PRs (will be copied)