terraform-provider-github
terraform-provider-github copied to clipboard
fix: imported custom property type
Imported custom properties currently default the type to null. This causes the state to then update with the real type value, which triggers a forced replacement. This fetches the type from the organization property schema and adds it on import.
Resolves #2639
Before the change?
- An imported custom property resource's
property_typeis set to null, which causes the configuration to trigger a forced replacement of the resource.
After the change?
- The property type is fetched from the organisation schema and set correctly, preventing the resource replacement.
Pull request checklist
- [x] Tests for the changes have been added (for bug fixes / features)
- [x] Docs have been reviewed and added / updated if needed (for bug fixes / features)
Does this introduce a breaking change?
Please see our docs on breaking changes to help!
- [ ] Yes
- [x] No
Thanks for the fix @imaspen , we are impacted by this as well. Hopefully GH brings it into one of the upcoming releases.