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

StateUpgrader only works with deprecated APIs #572

Closed
iwarapter opened this issue Dec 9, 2022 · 3 comments
Closed

StateUpgrader only works with deprecated APIs #572

iwarapter opened this issue Dec 9, 2022 · 3 comments
Labels
bug Something isn't working
Milestone

Comments

@iwarapter
Copy link
Contributor

Module version

github.com/hashicorp/terraform-plugin-framework v0.17.0

Relevant provider source code

return map[int64]resource.StateUpgrader{
  0: {
    PriorSchema: &schema.Schema{
      Attributes: map[string]schema.Attribute{
	"id": schema.StringAttribute{
          Required: true,
	},
      },
    },
    StateUpgrader: func(...

Terraform Configuration Files

N/A

Expected Behavior

The new separated APIs should work with StateUpgraders, i'm assuming this hasn't been done as it's planned for the removal of the deprecated APIs.

Actual Behavior

Doesn't compile.

Steps to Reproduce

References

@iwarapter iwarapter added the bug Something isn't working label Dec 9, 2022
iwarapter added a commit to iwarapter/terraform-plugin-framework that referenced this issue Dec 9, 2022
@bflad
Copy link
Member

bflad commented Dec 11, 2022

Thank you for catching this, @iwarapter. 😄 This was a miss on my part during the tfsdk.Schema deprecation effort. The intention would be to require resource/schema.Schema there, similar to the other resource schema handling. It looks like you submitted #573 to cover this, which we can review shortly.

@bflad
Copy link
Member

bflad commented Dec 13, 2022

#573 was merged. 👍

@bflad bflad closed this as completed Dec 13, 2022
@github-actions
Copy link

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jan 13, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants