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

Panic in muxer when attaching with PULUMI_DEBUG_PROVIDERS #2088

Closed
guineveresaenger opened this issue Jun 12, 2024 · 0 comments · Fixed by #2091
Closed

Panic in muxer when attaching with PULUMI_DEBUG_PROVIDERS #2088

guineveresaenger opened this issue Jun 12, 2024 · 0 comments · Fixed by #2091
Assignees
Labels
kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed

Comments

@guineveresaenger
Copy link
Contributor

What happened?

Following debug provider steps in p-aws, upon starting a program using PULUMI_DEBUG_PROVIDERS and the exposed port, the process crashes.

Example

Got a connection, launched process /Users/guin/go/src/github.com/pulumi/pulumi-aws/bin/pulumi-resource-aws (pid = 97357).
55429
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x2 addr=0x0 pc=0x1059f7714]

goroutine 55 [running]:
github.com/pulumi/pulumi/pkg/v3/resource/provider.(*HostClient).Close(0x0)
        /Users/guin/go/pkg/mod/github.com/pulumi/pulumi/pkg/v3@v3.119.0/resource/provider/host.go:62 +0x24
github.com/pulumi/pulumi-terraform-bridge/x/muxer.(*muxer).Attach(0x140038df3e0, {0x11c57f200, 0x14007632c30}, 0x1400764e240)
        /Users/guin/go/src/github.com/pulumi/pulumi-terraform-bridge/x/muxer/muxer.go:438 +0x250
github.com/pulumi/pulumi/sdk/v3/proto/go._ResourceProvider_Attach_Handler.func1({0x11c57f200, 0x14007632c30}, {0x11b376520, 0x1400764e240})
        /Users/guin/go/pkg/mod/github.com/pulumi/pulumi/sdk/v3@v3.119.0/proto/go/provider_grpc.pb.go:777 +0xbc
github.com/grpc-ecosystem/grpc-opentracing/go/otgrpc.OpenTracingServerInterceptor.func1({0x11c57f200, 0x14007632c30}, {0x11b376520, 0x1400764e240}, 0x14007636180, 0x1400250a360)
        /Users/guin/go/pkg/mod/github.com/grpc-ecosystem/grpc-opentracing@v0.0.0-20180507213350-8e809c8a8645/go/otgrpc/server.go:57 +0x574
github.com/pulumi/pulumi/sdk/v3/proto/go._ResourceProvider_Attach_Handler({0x11c166b20, 0x140038df3e0}, {0x11c57f200, 0x140076329f0}, 0x14007634300, 0x14002f7efc0)
        /Users/guin/go/pkg/mod/github.com/pulumi/pulumi/sdk/v3@v3.119.0/proto/go/provider_grpc.pb.go:779 +0x1e4
google.golang.org/grpc.(*Server).processUnaryRPC(0x14002f26200, {0x11c57f200, 0x14007632960}, {0x11c5cd440, 0x1400764c000}, 0x14007662120, 0x14003a84180, 0x125aeaa80, 0x0)
        /Users/guin/go/pkg/mod/google.golang.org/grpc@v1.63.2/server.go:1369 +0x13a4
google.golang.org/grpc.(*Server).handleStream(0x14002f26200, {0x11c5cd440, 0x1400764c000}, 0x14007662120)
        /Users/guin/go/pkg/mod/google.golang.org/grpc@v1.63.2/server.go:1780 +0xd0c
google.golang.org/grpc.(*Server).serveStreams.func2.1()
        /Users/guin/go/pkg/mod/google.golang.org/grpc@v1.63.2/server.go:1019 +0x144
created by google.golang.org/grpc.(*Server).serveStreams.func2 in goroutine 53
        /Users/guin/go/pkg/mod/google.golang.org/grpc@v1.63.2/server.go:1030 +0x1c8
Exiting.

Output of pulumi about

CLI          
Version      3.116.1
Go Version   go1.22.3
Go Compiler  gc

Plugins
KIND      NAME    VERSION
resource  aws     6.39.1
resource  awsx    2.11.0
resource  docker  4.5.4
resource  docker  3.6.1
language  nodejs  unknown

Host     
OS       darwin
Version  13.5
Arch     arm64

This project is written in nodejs: executable='/opt/homebrew/bin/node' version='v21.6.0'

Current Stack: guinevere-pulumi-corp/bridge-2020/dev

Found no resources associated with dev

Found no pending operations associated with dev

Backend        
Name           pulumi.com
URL            https://app.pulumi.com/guinevere-pulumi-corp
User           guinevere-pulumi-corp
Organizations  guinevere-pulumi-corp, pulumi
Token type     personal

Dependencies:
NAME            VERSION
@pulumi/aws     6.39.1
@pulumi/awsx    2.11.0
@pulumi/pulumi  3.119.0
@types/node     18.19.34
typescript      5.4.5

Additional context

Prior attempt to fix: #1716

Contributing

Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

@guineveresaenger guineveresaenger added needs-triage Needs attention from the triage team kind/bug Some behavior is incorrect or out of spec labels Jun 12, 2024
@guineveresaenger guineveresaenger self-assigned this Jun 12, 2024
@guineveresaenger guineveresaenger removed the needs-triage Needs attention from the triage team label Jun 12, 2024
@pulumi-bot pulumi-bot added the resolution/fixed This issue was fixed label Jun 14, 2024
VenelinMartinov added a commit that referenced this issue Oct 8, 2024
Bumps the muxer to the latest version.

Contains a fix for provider debug attachment panic from June
#2088

#1445 would have
helped here
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Some behavior is incorrect or out of spec resolution/fixed This issue was fixed
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants