Hi everyone, we have recently received this error ...
# pulumiverse
r
Hi everyone, we have recently received this error in our pulumi-cpln
upgrade-provider
job, can anyone help?
Copy code
Error: ../../../../go/pkg/mod/github.com/pulumi/terraform-plugin-sdk/v2@v2.0.0-20230912190043-e6d96b3b8f7e/helper/schema/provider.go:511:9: cannot use NewGRPCProviderServer(p) (value of type *GRPCProviderServer) as tfprotov5.ProviderServer value in return statement: *GRPCProviderServer does not implement tfprotov5.ProviderServer (missing method CallFunction)
Error reference: https://github.com/pulumiverse/pulumi-cpln/actions/runs/12229415412/job/34109156135#step:2:765 Workflow: https://github.com/pulumiverse/pulumi-cpln/blob/main/.github/workflows/upgrade-provider.yml
b
@rapid-parrot-24984 Please ensure that the Go.mod redirect for the terraform-plugin-sdk points to the version that is required by the version of Terraform Bridge you're using.
r
Sorry for the late reply, got busy with higher priority issues. Now, I’m reviewing this and I am unsure of where to locate the version needed by the Pulumi Terraform Bridge. Could you please guide me in finding it?
b
@rapid-parrot-24984 you're using the Pulumi GitHub pulumi-upgrade-provider-action which basically is a wrapper for github.com/pulumi/upgrade-provider . Perhaps you should get in contact with @ancient-policeman-24615 or @happy-parrot-60128 seems that there is a an issue either in the configuration for pulumi-upgrade-provider-action or you're faciung a bug of upgrade-provider with pulumi-cpln provider.
Because I was curious how well the upgrade-provider tool is performing right now, I tested to upgrade pulumi-terraform-bridge and the upstream provider on the pulumiverse/pulumi-time provider, but that didn't play out well. First issue: unable to upgrade the the provider. The tool stopped with exit code 1:
Copy code
---- Setting Up Environment ----
- ✓ GOWORK="off": done
- ✓ PULUMI_MISSING_DOCS_ERROR="true": done
- ✓ PULUMI_CONVERT_EXAMPLES_CACHE_DIR="": done
---- Discovering Repository ----
- Ensure '<http://github.com/pulumiverse/pulumi-time|github.com/pulumiverse/pulumi-time>'
  - ✓ Expected Location: /home/vagrant/work/pulumi-time
  - ✓ Downloading: skipped - already exists
  - ✓ Validating: done
- pull default branch
  - ✓ /usr/bin/git ls-remote --heads origin: done
  - ✓ finding default branch: main
  - ✓ /usr/bin/git fetch: done
  - ✓ /usr/bin/git checkout main: done
  - ✓ /usr/bin/git pull origin: done
- ✓ Repo kind: shimmed
- X Planning Provider Update: exit status 1
Secondly it wasn't able to upgrade to the required terraform bridge version correctly:
Copy code
---- Setting Up Environment ----
- ✓ GOWORK="off": done
- ✓ PULUMI_MISSING_DOCS_ERROR="true": done
- ✓ PULUMI_CONVERT_EXAMPLES_CACHE_DIR="": done
---- Discovering Repository ----
- Ensure '<http://github.com/pulumiverse/pulumi-time|github.com/pulumiverse/pulumi-time>'
  - ✓ Expected Location: /home/vagrant/work/pulumi-time
  - ✓ Downloading: skipped - already exists
  - ✓ Validating: done
- pull default branch
  - ✓ /usr/bin/git ls-remote --heads origin: done
  - ✓ finding default branch: main
  - ✓ /usr/bin/git fetch: done
  - ✓ /usr/bin/git checkout main: done
  - ✓ /usr/bin/git pull origin: done
- ✓ Repo kind: shimmed
- ✓ Planning Bridge Update: v3.89.1 -> v3.98.0
---- Update Artifacts ----
- Ensure Branch
  - ✓ /usr/bin/git branch: done
  - ✓ Already exists: no
  - ✓ /usr/bin/git checkout -b upgrade-pulumi-terraform-bridge-to-v3.98.0: done
  - ✓ /usr/bin/git checkout upgrade-pulumi-terraform-bridge-to-v3.98.0: done
- ✓ /home/vagrant/.gobrew/current/bin/go get <http://github.com/pulumi/pulumi-terraform-brid|github.com/pulumi/pulumi-terraform-brid>...: done
- X /home/vagrant/.gobrew/current/bin/go mod tidy: exit status 1:
go: downloading <http://github.com/pulumi/pulumi-terraform-bridge/pf|github.com/pulumi/pulumi-terraform-bridge/pf> v0.42.1
go: downloading <http://github.com/hashicorp/terraform-provider-time|github.com/hashicorp/terraform-provider-time> v0.12.0
go: downloading <http://github.com/hashicorp/terraform-plugin-sdk|github.com/hashicorp/terraform-plugin-sdk> v1.7.0
go: downloading <http://github.com/pulumi/terraform-plugin-sdk/v2|github.com/pulumi/terraform-plugin-sdk/v2> v2.0.0-20240520223432-0c0bf0d65f10
go: downloading <http://github.com/hashicorp/terraform-plugin-framework|github.com/hashicorp/terraform-plugin-framework> v1.11.0
go: downloading <http://github.com/zclconf/go-cty|github.com/zclconf/go-cty> v1.14.4
go: downloading <http://github.com/hashicorp/terraform-plugin-framework-validators|github.com/hashicorp/terraform-plugin-framework-validators> v0.13.0
go: downloading <http://github.com/pulumi/pulumi-terraform-bridge/x/muxer|github.com/pulumi/pulumi-terraform-bridge/x/muxer> v0.0.8
go: downloading <http://github.com/hashicorp/go-version|github.com/hashicorp/go-version> v1.7.0
go: downloading <http://github.com/hashicorp/terraform-plugin-framework-timetypes|github.com/hashicorp/terraform-plugin-framework-timetypes> v0.4.0
go: downloading <http://github.com/hashicorp/terraform-plugin-testing|github.com/hashicorp/terraform-plugin-testing> v1.9.0
go: downloading <http://github.com/zclconf/go-cty-debug|github.com/zclconf/go-cty-debug> v0.0.0-20240509010212-0d6042c53940
go: downloading <http://github.com/hashicorp/terraform-json|github.com/hashicorp/terraform-json> v0.22.1
go: downloading <http://github.com/olekukonko/tablewriter|github.com/olekukonko/tablewriter> v0.0.5
go: downloading <http://github.com/ProtonMail/go-crypto|github.com/ProtonMail/go-crypto> v1.1.0-alpha.2
go: downloading <http://github.com/hashicorp/hc-install|github.com/hashicorp/hc-install> v0.7.0
go: downloading <http://github.com/stretchr/objx|github.com/stretchr/objx> v0.5.2
go: downloading <http://cloud.google.com/go/compute|cloud.google.com/go/compute> v1.25.0
go: downloading <http://github.com/hashicorp/terraform-registry-address|github.com/hashicorp/terraform-registry-address> v0.2.3
go: downloading <http://github.com/hashicorp/go-checkpoint|github.com/hashicorp/go-checkpoint> v0.5.0
go: finding module for package <http://github.com/pulumi/pulumi-terraform-bridge/v3/unstable/logging|github.com/pulumi/pulumi-terraform-bridge/v3/unstable/logging>
go: downloading <http://github.com/pulumi/pulumi-terraform-bridge|github.com/pulumi/pulumi-terraform-bridge> v1.8.4
go: <http://github.com/pulumiverse/pulumi-time/provider|github.com/pulumiverse/pulumi-time/provider> imports
        <http://github.com/pulumi/pulumi-terraform-bridge/pf/tfbridge|github.com/pulumi/pulumi-terraform-bridge/pf/tfbridge> imports
        <http://github.com/pulumi/pulumi-terraform-bridge/v3/unstable/logging|github.com/pulumi/pulumi-terraform-bridge/v3/unstable/logging>: module <http://github.com/pulumi/pulumi-terraform-bridge/v3@latest|github.com/pulumi/pulumi-terraform-bridge/v3@latest> found (v3.98.0), but does not contain package <http://github.com/pulumi/pulumi-terraform-bridge/v3/unstable/logging|github.com/pulumi/pulumi-terraform-bridge/v3/unstable/logging>
By using my manual approach to upgrade terraform bridge everything worked well. (screenshot)
r
I implemented the solution above in my go.mod file and for some reason, the
build-sdk (python)
workflow keeps failing. https://github.com/pulumiverse/pulumi-cpln/actions/runs/12570159925/job/35039650331?pr=60 At this point I am not sure what to do, can you take a look at this PR I created for the implementation? https://github.com/pulumiverse/pulumi-cpln/pull/60
b
@rapid-parrot-24984 every time you change the version of either • the upstream Terraform provider, • the Pulumi Terraform Bridge or • the Go version you must recreate all program language SDKs locally
make build_sdks
and check in and push the changes. The GitHub workflows for the Pulumi providers always contain a step to verify that the language SDKs are not out of sync with the provider. And exactly that step is failing for Python.