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

[HPR-1108] Add compile time check for go-cty #186

Merged
merged 2 commits into from
Jun 15, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
11 changes: 10 additions & 1 deletion rpc/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,16 @@ underpins the packer server that all plugins must implement.
*/
package rpc

import "encoding/gob"
import (
"encoding/gob"

"github.com/zclconf/go-cty/cty"
)

// Test that cty types implement the gob.GobEncoder interface.
// Support for encoding/gob was removed in github.com/zclconf/go-cty@v1.11.0.
// Refer to issue https://github.com/hashicorp/packer-plugin-sdk/issues/187
var _ gob.GobEncoder = cty.Value{}

func init() {
gob.Register(new(map[string]string))
Expand Down