UpgradeQuick mode fails on some providers
guineveresaenger opened this issue · 1 comments
Upstream GCP v5.0.0 added a new function that requires a field called Meta
to be non-nil.
Meta
is set in the terraform-plugin-sdk and it appears to need Configure() to be called to be nonnil.
Replay tests for providers requiring this information upfront will need to take this into consideration.
Expand for panic stack trace
``` === RUN TestDNSRecordSet === RUN TestDNSRecordSet/upgrade-snapshot provider_test.go:117: Skip recording baseline behavior because -provider-snapshot flag is unset and PULUMI_PROVIDER_TEST_MODE="snapshot" is unset === RUN TestDNSRecordSet/upgrade-preview-only upgrade.go:240: Skipping in -short mode === RUN TestDNSRecordSet/upgrade-quick --- FAIL: TestDNSRecordSet (0.08s) --- SKIP: TestDNSRecordSet/upgrade-snapshot (0.00s) --- SKIP: TestDNSRecordSet/upgrade-preview-only (0.00s) --- FAIL: TestDNSRecordSet/upgrade-quick (0.01s) panic: interface conversion: interface {} is nil, not *transport.Config [recovered] panic: interface conversion: interface {} is nil, not *transport.Configgoroutine 13 [running]:
testing.tRunner.func1.2({0x51da900, 0xc001a25aa0})
/usr/local/Cellar/go/1.21.3/libexec/src/testing/testing.go:1545 +0x238
testing.tRunner.func1()
/usr/local/Cellar/go/1.21.3/libexec/src/testing/testing.go:1548 +0x397
panic({0x51da900?, 0xc001a25aa0?})
/usr/local/Cellar/go/1.21.3/libexec/src/runtime/panic.go:914 +0x21f
github.com/hashicorp/terraform-provider-google-beta/google-beta/tpgresource.DefaultProviderProject({0xc001a258f0?, 0xc001975770?}, 0xc001a25920?, {0x0?, 0x0?})
/Users/guin/go/src/github.com/pulumi/pulumi-gcp/upstream/google-beta/tpgresource/utils.go:751 +0x12a
github.com/hashicorp/terraform-provider-google-beta/google-beta/services/compute.ResourceComputeInstance.All.func16({0x64b2c10, 0x8c0f140}, 0x597e325?, {0x0, 0x0})
/Users/guin/go/pkg/mod/github.com/pulumi/terraform-plugin-sdk/v2@v2.0.0-20230912190043-e6d96b3b8f7e/helper/customdiff/compose.go:53 +0xab
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.schemaMap.Diff(0xc000135e90, {0x64b2c10, 0x8c0f140}, 0xc000e0f110, 0xc001330f60, 0xc0007c1ee0, {0x0, 0x0}, 0x0)
/Users/guin/go/pkg/mod/github.com/pulumi/terraform-plugin-sdk/v2@v2.0.0-20230912190043-e6d96b3b8f7e/helper/schema/schema.go:698 +0x4b4
github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema.(*Resource).SimpleDiff(0x0?, {0x64b2c10?, 0x8c0f140?}, 0xc000e0f110, 0xc000e0ea90?, {0x0?, 0x0?})
/Users/guin/go/pkg/mod/github.com/pulumi/terraform-plugin-sdk/v2@v2.0.0-20230912190043-e6d96b3b8f7e/helper/schema/resource.go:967 +0xd5
github.com/pulumi/pulumi-terraform-bridge/v3/pkg/tfshim/sdk-v2.v2Provider.simpleDiff({0x0?, {0xffffffffffffffff?, 0xc00150f6a8?, 0x1ae97e3?}}, 0x5149b80?, 0xc001330d80?, 0x0?, 0xc00150f778?, {{{0x64b3058, 0xc000880d60}}, ...}, ...)
/Users/guin/go/pkg/mod/github.com/pulumi/pulumi-terraform-bridge/v3@v3.63.2/pkg/tfshim/sdk-v2/provider_diff.go:101 +0x8da
github.com/pulumi/pulumi-terraform-bridge/v3/pkg/tfshim/sdk-v2.v2Provider.Diff({0xc000e67620?, {0x0?, 0x0?, 0x0?}}, {0x59b2887, 0x17}, {0x64b2e98?, 0xc000b69938}, {0x647f300, 0xc001330f60})
/Users/guin/go/pkg/mod/github.com/pulumi/pulumi-terraform-bridge/v3@v3.63.2/pkg/tfshim/sdk-v2/provider_diff.go:63 +0x2d2
</details>
panic: interface conversion: interface {} is nil, not *transport.Config [recovered]
panic: interface conversion: interface {} is nil, not *transport.Config
Happens on https://github.com/pulumi/pulumi-gcp/actions/runs/6699923625/job/18204946008
It seems that after upgrading GCP to latest version it started hard-depending on being configured, while currently the Quick mode skips the Configure call, which is inappropriate for this provider now.