You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was using it in my go.mod project and encountered an error: error loading plugin plugin was built with a different version of package internal/abi
#159
Open
dairui520 opened this issue
Jul 11, 2024
· 0 comments
My scenario is: deploy a go service and execute code dynamically by passing parameters. But after deploying the service, this error occurs. If I remove the third-party package, it runs normally.
code:
import (
"fmt"
"github.com/spf13/cast"
"github.com/bytedance/sonic"
)
func getData(m map[string]interface{}) (string, error) {
res :=""
for _, v := range m {
res += cast.ToString(v)
}
return sonic.MarshalString(m)
}
Service Log:
go: added github.com/bytedance/sonic/loader v0.1.1
go: added github.com/cloudwego/base64x v0.1.4
go: added github.com/cloudwego/iasm v0.2.0
go: added github.com/klauspost/cpuid/v2 v2.0.9
go: added github.com/spf13/cast v1.6.0
go: added github.com/twitchyliquid64/golang-asm v0.15.1
go: added golang.org/x/arch v0.0.0-20210923205945-b76863e36670
// debug: running "go mod tidy" ...
// debug: compiling plugin "/Users/go/src/gomacro.imports/gomacro_pid_25968/import_2" ...
error loading plugin "/Users/go/src/gomacro.imports/gomacro_pid_25968/import_2/import_2.so": plugin.Open("/Users/go/src/gomacro.imports/gomacro_pid_25968/import_2/import_2"): plugin was built with a different version of package internal/abi
repl.go:13:10: undefined "cast" in cast.ToString <*ast.SelectorExpr>
The text was updated successfully, but these errors were encountered:
dairui520
changed the title
I use it in the go.mod project and encounter errors. I don't know how to fix it
I was using it in my go.mod project and encountered an error: error loading plugin plugin was built with a different version of package internal/abi
Jul 11, 2024
My scenario is: deploy a go service and execute code dynamically by passing parameters. But after deploying the service, this error occurs. If I remove the third-party package, it runs normally.
code:
Service Log:
The text was updated successfully, but these errors were encountered: