Skip to content
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

helper/plugin: Allow missing MigrateState for provider flatmap state upgrades #21625

Merged
merged 1 commit into from
Jun 10, 2019

Conversation

bflad
Copy link
Contributor

@bflad bflad commented Jun 6, 2019

Reference: hashicorp/terraform-provider-aws#8828

Prior to Terraform 0.12, providers were not required to implement the MigrateState function when increasing the SchemaVersion above 0. Effectively there is no flatmap state difference between version 0 and defined SchemaVersion or lowest StateUpgrader Version (whichever is lowest) when MigrateState is undefined, so here we remove the error and increase the schema version automatically.

…upgrades

Reference: hashicorp/terraform-provider-aws#8828

Prior to Terraform 0.12, providers were not required to implement the `MigrateState` function when increasing the `SchemaVersion` above `0`. Effectively there is no flatmap state difference between version 0 and defined `SchemaVersion` or lowest `StateUpgrader` `Version` (whichever is lowest) when `MigrateState` is undefined, so here we remove the error and increase the schema version automatically.
@jbardin jbardin merged commit c502b4c into master Jun 10, 2019
@jbardin jbardin deleted the f-allow-missing-MigrateState branch June 10, 2019 21:35
@apremalal
Copy link

Thanks for the fix. This is much needed. Can we expect a new release with this soon?

@ghost
Copy link

ghost commented Jul 25, 2019

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Jul 25, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants